Skip to content

Commit 58fb7af

Browse files
author
daffl
committed
Added forced linebreaks to documentation
1 parent 0b17b64 commit 58fb7af

File tree

2 files changed

+66
-485
lines changed

2 files changed

+66
-485
lines changed

readme.markdown

+66-66
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ __Some things you can do:__
55

66
* use JavaScript and JSON instead of HTML markup since your page doesn't run without JS anyway
77
* naturally generate JavaScript enhanced markup with your own extensions and custom types
8-
* have an easy way to include jQuery UI elements and JavaScript validation (both supported out of the box)
8+
* have an easy way to include jQuery UI elements and other popular jQuery plugins (some supported out of the box)
99
* scaffold forms from business objects of your server side framework
1010

1111
## Get started:
@@ -55,63 +55,63 @@ __Learn more:__
5555

5656
Type Generators are functions that return a new jQuery DOM object for a specific type. If there is no Type Generator
5757
with a given name, a basic HTML element with that tag name will be created. Every other key in the JavaScript or JSON object
58-
you pass will be used as an HTML attribute. An exception is, if there is a Subscriber registered for that ke (more about
58+
you pass will be used as an HTML attribute. An exception is, if there is a Subscriber registered for that key (more about
5959
this in the next section). A plugin call like this:
6060

6161
$('#my-div').dform({
6262
type : "span",
6363
id : "the-span"
6464
});
6565

66-
Will append an empty `<span id="the-span"></span>` tag to the element with the id my-div.
66+
Will append an empty `<span id="the-span"></span>` tag to the selected element.
6767

6868
### Core types
6969

7070
Besides standard HTML tags the following core types are supported:
7171

72-
**container** `{ "type" : "container" }`
73-
Creates a \<div\> container (you can also use `{ "type" : "div" }`)
72+
**container** `{ "type" : "container" }`<br />
73+
Creates a `<div>` container (you can also use `{ "type" : "div" }`)
7474

75-
**text** `{ "type" : "text" }`
75+
**text** `{ "type" : "text" }`<br />
7676
Creates a text input field
7777

78-
**password** `{ "type" : "password" }`
78+
**password** `{ "type" : "password" }`<br />
7979
Creates a password input field
8080

81-
**submit** `{ "type" : "submit" }`
81+
**submit** `{ "type" : "submit" }`<br />
8282
Creates a submit button input element
8383

84-
**reset** `{ "type" : "reset" }`
84+
**reset** `{ "type" : "reset" }`<br />
8585
Creates a reset button input element
8686

87-
**hidden** `{ "type" : "hidden" }`
87+
**hidden** `{ "type" : "hidden" }`<br />
8888
Creates a hidden input element
8989

90-
**file** `{ "type" : "file" }`
90+
**file** `{ "type" : "file" }`<br />
9191
Create a file upload field
9292

93-
**radio** `{ "type" : "radio" }`
93+
**radio** `{ "type" : "radio" }`<br />
9494
Creates a radio button
9595

96-
**checkbox** `{ "type" : "checkbox" }`
96+
**checkbox** `{ "type" : "checkbox" }`<br />
9797
Creates a checkbox
9898

99-
**radiobuttons** `{ "type" : "radiobuttons" }`
99+
**radiobuttons** `{ "type" : "radiobuttons" }`<br />
100100
Creates a group of radiobuttons (uses options subscriber explained below)
101101

102-
**checkboxes** `{ "type" : "checkboxes" }`
102+
**checkboxes** `{ "type" : "checkboxes" }`<br />
103103
Creates a group of checkboxes
104104

105-
**number** `{ "type" : "number" }`
105+
**number** `{ "type" : "number" }`<br />
106106
Creates an HTML 5 number input field
107107

108-
**url** `{ "type" : "url" }`
108+
**url** `{ "type" : "url" }`<br />
109109
Creates an HTML 5 url input field
110110

111-
**tel** `{ "type" : "tel" }`
111+
**tel** `{ "type" : "tel" }`<br />
112112
Creates an HTML 5 phone number input field
113113

114-
**email** `{ "type" : "email" }`
114+
**email** `{ "type" : "email" }`<br />
115115
Creates an HTML 5 email input field
116116

117117
### Add your own
@@ -126,7 +126,7 @@ have been registered for when traversing the dForm object.
126126

127127
### Core subscribers
128128

129-
**type** *{String}*
129+
**type** *{String}*<br />
130130
Besides looking up the correct Type Generator it also adds a dform specific class to the element using
131131
*$.dform.options.prefix* (*ui-dform-* by default) and the type name.
132132

@@ -138,7 +138,7 @@ Generates:
138138

139139
<input type="text" class="ui-dform-text" />
140140

141-
**class** *{String}*
141+
**class** *{String}*<br />
142142
Adds a class to the current element (instead of setting the attribute)
143143

144144
{
@@ -150,7 +150,7 @@ Generates:
150150

151151
<div class="ui-dform-div the-div container"></div>
152152

153-
**html/elements** *{String|Array|Object}*
153+
**html/elements** *{String|Array|Object}*<br />
154154
Based on the options it either sets the HTML string content of the current element or appends one or an array
155155
of dForm objects (the elements subscriber does the same but is kept for backwards compatibility).
156156

@@ -191,7 +191,7 @@ Generates:
191191
</div>
192192
</div>
193193

194-
**value** *{String|Function}*
194+
**value** *{String|Function}*<br />
195195
Sets the value of the element using .val()
196196

197197
{
@@ -203,7 +203,7 @@ Generates:
203203

204204
<input type="text" value="Text content" />
205205

206-
**css** {Object}
206+
**css** {Object}<br />
207207
Sets CSS properties on an element:
208208

209209
{
@@ -218,7 +218,7 @@ Generates:
218218

219219
<div class="ui-dform-div" style="background-color: #FF0000; display: none;"></div>
220220

221-
**options** *{Object}*
221+
**options** *{Object}*<br />
222222
Generates a list of options from a value to text (or dForm Object) mapping for elements of type *select*, *radiobuttons*
223223
or *checkboxes*.
224224

@@ -261,7 +261,7 @@ Generates:
261261

262262
// TODO
263263

264-
**caption** *{String|Object}*
264+
**caption** *{String|Object}*<br />
265265
Adds a caption to the element. The type used for it depends on the element type:
266266
* A *legend* on *fieldset* elements
267267
* A *label* next to *radio* or *checkbox* elements
@@ -293,7 +293,7 @@ Generates:
293293
<legend type="ui-dform-legend">Address</label>
294294
</fieldset>
295295

296-
**url**
296+
**url**<br />
297297
TODO
298298

299299
### Add your own
@@ -304,21 +304,21 @@ You can add your own subscribers
304304

305305
Currently there are two types of special subscribers
306306

307-
**\[pre\]** *{Object}*
307+
**\[pre\]** *{Object}*<br />
308308
Functions registered with this name will be called before any processing occurs and get the original options passed.
309309

310-
**\[post\]** *{Object}*
310+
**\[post\]** *{Object}*<br />
311311
Functions registered with this name will be called after all processing is finished and also get the original
312312
options passed.
313313

314314
## Plugin methods
315315

316316
Default
317317

318-
run
319-
append
320-
attr({Object})
321-
ajax
318+
run<br />
319+
append<br />
320+
attr({Object})<br />
321+
ajax<br />
322322

323323
## jQuery UI
324324

@@ -338,54 +338,54 @@ ajax
338338

339339
**0.2.0**
340340

341-
Full QUnit test suite
342-
Improved documentation
343-
Changed API
344-
Added deferred loading of subscribers
341+
- Full QUnit test suite
342+
- Improved documentation
343+
- Changed API
344+
- Added deferred loading of subscribers
345345

346346
**0.1.4**
347347

348-
Merged pull request [#30](https://github.com/daffl/jquery.dform/pull/30): Wrap 'type' as an array so it doesn't break jQuery 1.7.1's $.inArray() when running in IE8
349-
Added first QUnit tests
350-
Fixed issue #22 with jQuery UI accordion causing problems with captions
351-
Removed placeholder plugin. Use HTML 5 placeholders or the jQuery [placeholder plugin](https://github.com/danielstocks/jQuery-Placeholder)
352-
Updated documentation engine to DocumentJS and build system to StealJS
353-
Merged pull request [#19](https://github.com/daffl/jquery.dform/pull/19) and [#20](https://github.com/daffl/jquery.dform/pull/20), support to set up a validate options for validate() in "form" type
354-
Merged pull request [#26](https://github.com/daffl/jquery.dform/pull/26) to support HTML 5 input types
355-
Added simple getting started example
348+
- Merged pull request [#30](https://github.com/daffl/jquery.dform/pull/30): Wrap 'type' as an array so it doesn't break jQuery 1.7.1's $.inArray() when running in IE8
349+
- Added first QUnit tests
350+
- Fixed issue #22 with jQuery UI accordion causing problems with captions
351+
- Removed placeholder plugin. Use HTML 5 placeholders or the jQuery [placeholder plugin](https://github.com/danielstocks/jQuery-Placeholder)
352+
- Updated documentation engine to DocumentJS and build system to StealJS
353+
- Merged pull request [#19](https://github.com/daffl/jquery.dform/pull/19) and [#20](https://github.com/daffl/jquery.dform/pull/20), support to set up a validate options for validate() in "form" type
354+
- Merged pull request [#26](https://github.com/daffl/jquery.dform/pull/26) to support HTML 5 input types
355+
- Added simple getting started example
356356

357357
**0.1.3**
358358

359-
Created some public [JSFiddles for trying the plugin](http://jsfiddle.net/user/Daff/fiddles)
360-
Created [jQuery.dForm Google Group](http://groups.google.com/group/jquery-dform)
361-
Added <form> type, unified <buildForm> usage
362-
Fixed [issue #14](https://github.com/daffl/jquery.dform/issues/closed#issue/14), setting type attribute properly in IE
363-
Added <getValueAt>
364-
Added <i18n> support using the [jQuery globalize](https://github.com/jquery/jquery-global) plugin
365-
Fixed minor bugs in dform plugins
359+
- Created some public [JSFiddles for trying the plugin](http://jsfiddle.net/user/Daff/fiddles)
360+
- Created [jQuery.dForm Google Group](http://groups.google.com/group/jquery-dform)
361+
- Added *form* type, unified *buildForm* usage
362+
- Fixed [issue #14](https://github.com/daffl/jquery.dform/issues/closed#issue/14), setting type attribute properly in IE
363+
- Added *getValueAt*
364+
- Added *i18n* support using the [jQuery globalize](https://github.com/jquery/jquery-global) plugin
365+
- Fixed minor bugs in dform plugins
366366

367367
**0.1.2**
368368

369-
Added <dformAttr> to add HTML attributes to elements
370-
Moved <placeholder> into a separate plugin
371-
Added <reset> button type
372-
Added dynamic form definition loading by passing a URL to the <buildForm> plugin function
373-
Added <ajax> subscriber using the <jQuery form plugin at http://jquery.malsup.com/form>
374-
Added the <defaultType> method to create any HTML element without having to register a type
375-
Improved build process
369+
- Added *dformAttr* to add HTML attributes to elements
370+
- Moved *placeholder* into a separate plugin
371+
- Added *reset* button type
372+
- Added dynamic form definition loading by passing a URL to the *buildForm* plugin function
373+
- Added *ajax* subscriber using the *jQuery form plugin at http://jquery.malsup.com/form*
374+
- Added the *defaultType* method to create any HTML element without having to register a type
375+
- Improved build process
376376

377377
**0.1.1**
378378

379-
Separated type and subscriber functions
380-
Added types <file>, <container>, <hidden>, <accordion>, <checkboxes> and <radiobuttons>
381-
Added auto class generation based on element type
382-
Finished jQuery UI <accordion> and unified with <tabs> usage
383-
Switched documentation to <Natualdocs at http://naturaldocs.org>
384-
Added build.xml for generating documentation and minifying JavaScript
379+
- Separated type and subscriber functions
380+
- Added types *file*, *container*, *hidden*, *accordion*, *checkboxes* and *radiobuttons*
381+
- Added auto class generation based on element type
382+
- Finished jQuery UI *accordion* and unified with *tabs* usage
383+
- Switched documentation to *Natualdocs at http://naturaldocs.org*
384+
- Added build.xml for generating documentation and minifying JavaScript
385385

386386
**0.1**
387387

388-
* Initial release
388+
- Initial release
389389

390390
## License
391391

0 commit comments

Comments
 (0)