semantic-forms 5.0.5 → 5.0.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md ADDED
@@ -0,0 +1,191 @@
1
+ ## 5.0.8
2
+
3
+ - Altered dark mode support so that it does not apply if the `<html>` or `<body>` tag has a class of `"light"`.
4
+ - Updated dependencies.
5
+
6
+ ## 5.0.7
7
+
8
+ - Fixed a bug where the responsive grid layout would not always line up correctly.
9
+ - Fixed a bug that prevented text from being longer than input element, causing graphical errors.
10
+ - Updated dependencies.
11
+
12
+ ## 5.0.6
13
+
14
+ - Added slicker live demo docs.
15
+ - Fixed a bug causing dark mode not to respect OS preference.
16
+ - Updated dependencies.
17
+
18
+ ## 5.0.5
19
+
20
+ - Added better error handling to the JS.
21
+ - Updated dependencies.
22
+
23
+ ## 5.0.4
24
+
25
+ - Fixed a periodic JS error.
26
+
27
+ ## 5.0.3
28
+
29
+ - Fixed a bug that prevented `semantic-forms` from detecting when you inserted new forms into the page.
30
+ - Updated dependencies.
31
+
32
+ ## 5.0.2
33
+
34
+ - Fixed a bug that would cause errors when `reinitialize()` was called.
35
+ - Fixed a bug that caused nested selects to lose their dropdown icon.
36
+ - Fixed a bug where required single checkboxes would not show an asterisk.
37
+ - Added a help text icon beside labels with a `title` attribute on their respective inputs, or on labels for checkboxes and radios. Enabled with a `data-show-help-icon` attribute.
38
+ - Updated various dependencies.
39
+
40
+ ## 5.0.1
41
+
42
+ - Fixed a bug that caused some devDependencies to end up in the production build.
43
+ - Updated various dependencies.
44
+
45
+ ## 5.0.0
46
+
47
+ - Breaking: Added JS module bundling to make it possible for you to import CJS, ESM, or a standalone version of the JavaScript in this library to your project. However you will need to change your imports to match the new file names. See README for details.
48
+ - Added show/hide toggle to password fields which can be disabled with a `data-no-reveal` attribute.
49
+ - Added hover text for the clear field button and the show/hide password button.
50
+ - Added ability to customize clear field button hover text and show/hide password button hover text using data attributes as well.
51
+ - Added support for undo/redo keyboard commands when pressing the clear field.
52
+ - Added test suite.
53
+ - Fixed some accessibility issues.
54
+ - Updated various dependencies.
55
+
56
+ ## 4.0.4
57
+
58
+ - Fixed a bug that caused menu items with buttons to appear as a list.
59
+ - Updated various dependencies.
60
+
61
+ ## 4.0.3
62
+
63
+ - Fixed bug in which a form entry consisting of a single checkbox would be misaligned.
64
+ - Fixed bug that prevented some inputs from expanding to the width of its container.
65
+ - Fixed bug in which CSS reset for elements within a semantic forms form was overly aggressive, making it harder to style unrelated content within such a form.
66
+ - Updated various dependencies.
67
+
68
+ ## 4.0.2
69
+
70
+ - Fixed a visual bug that occurred when single checkbox elements had extra elements included.
71
+ - Updated various dependencies.
72
+
73
+ ## 4.0.1
74
+
75
+ - Added invalid help text support.
76
+ - Fixed a bug that caused float labels to break when certain browser extensions were enabled.
77
+
78
+ ## 4.0.0
79
+
80
+ - Breaking: Overhauled entire codebase to drive it using mostly CSS grid instead of flexbox. This makes everything more flexible overall and fit more designs better. However the CSS and markup changes will likely cause breaking changes to previous integrations, so when upgrading make some time to visually test all your pages to alter any CSS overrides you had in place accordingly. You also might want to make some markup changes to make use of new available classes to tweak the fit of individual form fields on specific forms.
81
+ - Altered fields to fit available space better at various screen sizes.
82
+ - Added multiple utility classes that define how wide inputs will span in the responsive layout.
83
+ - Added support for input type=image.
84
+ - Added support for secondary labels.
85
+ - Added styling for invalid form fields.
86
+ - Added asterisk that appears on required inputs.
87
+ - Improved accessibility considerably. Now has 100% Lighthouse score.
88
+ - Added feature to progressively nest fieldsets with progressively darker/lighter background colors.
89
+ - Fixed bug causing clear button appearing on disabled inputs.
90
+ - Fixed bug causing clear button to overlap with scrollbars on textareas.
91
+ - Fixed bug causing nested fieldset to have incorrect padding and margins.
92
+ - Fixed various other small bugs.
93
+ - Replaced the `less` CSS preprocessor with `sass`.
94
+ - Updated various dependencies.
95
+
96
+ ## 3.2.1
97
+
98
+ - Fixed a bug that could cause checkboxes and radio buttons to not submit their values to the server properly.
99
+ - Updated various dependencies.
100
+
101
+ ## 3.2.0
102
+
103
+ - Added a reinitialization method to re-scan existing forms. Called with `window.semanticForms.reinitialize(formName)`.
104
+ - Altered logic to enhance forms so that it now ignores inputs that have already been enhanced.
105
+ - Updated dependencies.
106
+
107
+ ## 3.1.0
108
+
109
+ - Added dark mode support.
110
+ - Deprecated "reset" versions and "no images" versions.
111
+ - Added mutation observer that monitors changes to the DOM and will enhance any additional `semanticForms` forms you insert, but the monitoring may not be perfect. If you want to re-scan for new forms to enhance manually, you may still need to call `window.semanticForms()`.
112
+ - Fixed a bug that caused DOM events to be duplicated when DOM elements are added dynamically after the first page load.
113
+ - Updated dependencies.
114
+
115
+ ## 3.0.8
116
+
117
+ - Fixed main export on case-sensitive file systems.
118
+ - Updated dependencies.
119
+
120
+ ## 3.0.7
121
+
122
+ - Fixed Chrome issue for forms with no placeholder.
123
+
124
+ ## 3.0.6
125
+
126
+ - Fixed missing files in npm package.
127
+
128
+ ## 3.0.5
129
+
130
+ - Added "reset" versions of the CSS files that set `all: unset;` before applying any semantic forms styles to help avoid conflicts with other CSS. There is a performance degradation to using this technique, so you should only use this if absolutely necessary.
131
+
132
+ ## 3.0.4
133
+
134
+ - Reduced size of select box text.
135
+
136
+ ## 3.0.3
137
+
138
+ - Fixed issue that prevented id selectors from allowing dots in the string.
139
+ - Fixed issue that prevented the clear field from dispatching an input event.
140
+
141
+ ## 3.0.2
142
+
143
+ - Added support for a single checkbox rather than a group of checkboxes.
144
+
145
+ ## 3.0.1
146
+
147
+ - Fixed alignment issue.
148
+
149
+ ## 3.0.0
150
+
151
+ - Removed default two column layout. Now defaults to as many columns as the container is wide.
152
+ - Added `x2` class you can put on `dd` elements to double the width of a form. Does not apply on small screens.
153
+
154
+ ## 2.1.2
155
+
156
+ - Added a function to the JS files's global scope called `semanticForms` that you can call to initialize new forms that have been added to the DOM since the initial initialization.
157
+ - Updated dependencies.
158
+
159
+ ## 2.1.1
160
+
161
+ - Fixed a situation that could lead to a JS error.
162
+ - Fix minor alignment issue.
163
+
164
+ ## 2.1.0
165
+
166
+ - Added all input types.
167
+ - Fixed clear field.
168
+ - Fixed markup mistakes in the examples.
169
+ - Fixed CSS to support `<menu>` elements correctly.
170
+ - Refactored the JavaScript to modernize it.
171
+ - Updated dependencies.
172
+
173
+ ## 2.0.0
174
+
175
+ - Replaced `<div class="buttonGroup">` with a `<menu>` element. You will need to refactor your HTML accordingly.
176
+ - Fixed alignment issue caused by browser engines changing their alignment calculations since the first release.
177
+ - Various other refactoring.
178
+ - Pinned deps.
179
+ - Updated dependencies.
180
+
181
+ ## 1.0.5
182
+
183
+ - Restricted JS events to target elements within `semanticForms` class form elements.
184
+ - Switched font sizes to % in case someone finds 16px too small and changes the default font size in the browser, these form fields will no longer stay fixed.
185
+ - Published to npm.
186
+ - Started CHANGELOG.
187
+ - Updated dependencies.
188
+
189
+ ## 1.0.4 and below
190
+
191
+ [Here be dragons](https://en.wikipedia.org/wiki/Here_be_dragons)...
@@ -0,0 +1,30 @@
1
+ # How to contribute to this project
2
+
3
+ ## Coding
4
+
5
+ - Fork/clone this repo.
6
+ - `npm ci`
7
+ - Make your changes. If you want to alter the CSS, do the changes in the `.scss` files.
8
+ - `npm run build`. The build step compiles the SCSS file into CSS.
9
+ - You can also run `npm run watch` automatically compiles the CSS file after a change is detected in the SCSS file.
10
+ - Test your changes by opening `semanticForms.html` in your browser.
11
+ - If you want to test your work on an actual HTTP server, run `npm run dev` or `npm run d`, and then visit http://localhost:3000/test/semanticForms
12
+ - Commit, push, open pull request.
13
+
14
+ ## Before opening a pull request
15
+
16
+ - Be sure all tests pass: `npm t`.
17
+ - Ensure 100% code coverage and write new tests if necessary: `npm run coverage`.
18
+ - Add your changes to `CHANGELOG.md`.
19
+
20
+ ## Release process
21
+
22
+ If you are a maintainer of this project, please follow the following release procedure:
23
+
24
+ - Merge all desired pull requests into master.
25
+ - Bump `package.json` to a new version and run `npm i` to generate a new `package-lock.json`.
26
+ - Alter CHANGELOG "Next version" section and stamp it with the new version.
27
+ - Paste contents of CHANGELOG into new version commit.
28
+ - Open and merge a pull request with those changes.
29
+ - Tag the merge commit as the a new release version number.
30
+ - Publish commit to npm.
package/README.md CHANGED
@@ -1,379 +1 @@
1
- # Semantic Forms
2
-
3
- [![Build Status](https://github.com/rooseveltframework/semantic-forms/workflows/CI/badge.svg
4
- )](https://github.com/rooseveltframework/semantic-forms/actions?query=workflow%3ACI) [![npm](https://img.shields.io/npm/v/semantic-forms.svg)](https://www.npmjs.com/package/semantic-forms)
5
-
6
- A pattern library of attractive forms for your website with the following design goals:
7
-
8
- - Attractive, modern float label visual design.
9
- - Responsive layout based on modern CSS grid technique.
10
- - Clear fields.
11
- - Light and dark mode.
12
- - Invalid field styling.
13
- - Good accessibility.
14
- - Semantic HTML (no div soup).
15
- - Uses a progressive enhancement approach so that core functionality and most of the features still work with JavaScript disabled.
16
- - Sets no global styles and is scoped by a single class name `semanticForms` applied to `<form>` elements.
17
- - No dependencies.
18
-
19
- See a [live demo here](https://rooseveltframework.github.io/semantic-forms/test/semanticForms.html).
20
-
21
- This module was built and is maintained by the [Roosevelt web framework](https://github.com/rooseveltframework/roosevelt) [team](https://github.com/orgs/rooseveltframework/people), but it can be used independently of Roosevelt as well.
22
-
23
- ## Install
24
-
25
- `npm install semantic-forms`
26
-
27
- The package is distributed with the following builds available:
28
-
29
- - `dist/semantic-forms.cjs`: CommonJS bundle: `const semanticForms = require('semantic-forms')`
30
- - `dist/semantic-forms.js`: Standalone bundle that can be included via `<script>` tags. Declares a global variable called: `semanticForms`
31
- - `dist/semantic-forms.min.js`: Minified standalone bundle that can be included via `<script>` tags. Declares a global variable called: `semanticForms`
32
- - `dist/semantic-forms.mjs`: ES module: `import semanticForms from 'semantic-forms'`
33
- - `dist/semantic-forms.min.mjs`: Minified ES module: `import semanticForms from 'semantic-forms/min'`
34
-
35
- ## Usage
36
-
37
- Include the `dist/semantic-forms.css` and whichever of the above versions of the JS file you prefer from this repo into your project.
38
-
39
- Then apply the `semanticForms` class to your `<form>` elements:
40
-
41
- ```html
42
- <form class="semanticForms">
43
- <!-- your form here -->
44
- </form>
45
- ```
46
-
47
- Then apply the JavaScript enhancements:
48
-
49
- ```javascript
50
- semanticForms()
51
- ```
52
-
53
- Then the CSS/JS enhancements to your forms will apply automatically, assuming the markup structure you use is one of the supported patterns.
54
-
55
- If you make changes to the DOM after Semantic Forms is activated and want to activate any additional `semanticForms` forms you insert, you can re-scan for new forms by calling `semanticForms.reinitialize()` again. If you only want to reinitialize one form instead of all of them, call `semanticForms.reinitialize(formElement)`.
56
-
57
- ## Features
58
-
59
- ### Float label inputs
60
-
61
- The float label input pattern is notoriously difficult to implement in a fashion that doesn't degrade HTML semantics or accessibility. This pattern library implements a solution that solves that problem. Your label doesn't need to be a sibling of your input like with other implementations. This implementation also has a custom clear button for each input.
62
-
63
- #### Example
64
-
65
- ```html
66
- <form class="semanticForms">
67
- <dl>
68
- <dt><label for="name">Name</label></dt>
69
- <dd><input id="name" name="name" type="text" placeholder="e.g. John Smith"></dd>
70
- </dl>
71
- </form>
72
- ```
73
-
74
- #### Or with a `<textarea>`
75
-
76
- ```html
77
- <form class="semanticForms">
78
- <dl>
79
- <dt><label for="textarea">Textarea</label></dt>
80
- <dd><textarea id="textarea" name="textarea" rows="5" cols="50" placeholder="e.g. Long string of text"></textarea></dd>
81
- </dl>
82
- </form>
83
- ```
84
-
85
- #### Add help text
86
-
87
- Include a label in the `<dd>` element with a matching `for` attribute to place help text beneath the input:
88
-
89
- ```html
90
- <form class="semanticForms">
91
- <dl>
92
- <dt><label for="password">Password</label></dt>
93
- <dd>
94
- <input id="password" name="password" type="password" placeholder="Enter a password" minlength="8" required>
95
- <label for="password">Must be at least 8 characters long.</label>
96
- </dd>
97
- </dl>
98
- </form>
99
- ```
100
-
101
- #### Customizing input fields
102
-
103
- By default, input fields will display an X icon to clear the text and password fields will also display a show/hide toggle for displaying the password in plain text. You can customize this behavior as follows:
104
-
105
- - Customize the hover text of the clear field button by applying a `data-clear-field-text="your text"` attribute to the input.
106
-
107
- - Customize the hover text of the show password button by applying a `data-show-password-text="your text"` attribute to the input.
108
-
109
- - Customize the hover text of the hide password button by applying a `data-hide-password-text="your text"` attribute to the input.
110
-
111
- - Prevent the show/hide toggle from appearing on password fields by applying a `data-no-reveal` attribute to the input.
112
-
113
- - Show a help text icon next to labels of inputs that contain a `title` attribute by applying a `data-show-help-icon` attribute to the label.
114
-
115
- - Note that checkboxes and radios should have a `title` attribute on the label instead of the inputs.
116
-
117
- ### Responsive columns
118
-
119
- This feature makes it so the form fields will grow, shrink, expand the number of columns, or reduce the number of columns based on how much space exists in the container. You can customize it by applying various `colspan-#` classes to various elements in the form markup structure.
120
-
121
- #### Set number of columns for a group of forms
122
-
123
- You can limit the number of columns on your forms using the `colspan-#` class on a `<dl>` element:
124
-
125
- ```html
126
- <form class="semanticForms">
127
- <dl class="colspan-2">
128
- <dt><label for="input-a">Input A</label></dt>
129
- <dd><input type="text" id="input-a" name="input-a"></dd>
130
-
131
- <dt><label for="input-b">Input B</label></dt>
132
- <dd><input type="text" id="input-b" name="input-b"></dd>
133
-
134
- <!-- wraps to the next row -->
135
- <dt><label for="input-c">Input C</label></dt>
136
- <dd><input type="text" id="input-c" name="input-c"></dd>
137
- </dl>
138
- </form>
139
- ```
140
-
141
- You can also apply the class to a `<fieldset>` which will apply that styling to all nested `<dl>` elements:
142
-
143
- ```html
144
- <form class="semanticForms">
145
- <fieldset class="colspan-3">
146
- <!-- inherits 3 column class -->
147
- <dl>
148
- <dt><label for="input-a">Input A</label></dt>
149
- <dd><input type="text" id="input-a" name="input-a"></dd>
150
-
151
- <dt><label for="input-b">Input B</label></dt>
152
- <dd><input type="text" id="input-b" name="input-b"></dd>
153
-
154
- <dt><label for="input-c">Input C</label></dt>
155
- <dd><input type="text" id="input-c" name="input-c"></dd>
156
- </dl>
157
-
158
- <!-- has 4 columns -->
159
- <dl class="colspan-4">
160
- <dt><label for="input-d">Input D</label></dt>
161
- <dd><input type="text" id="input-d" name="input-d"></dd>
162
-
163
- <dt><label for="input-e">Input E</label></dt>
164
- <dd><input type="text" id="input-e" name="input-e"></dd>
165
-
166
- <dt><label for="input-f">Input F</label></dt>
167
- <dd><input type="text" id="input-f" name="input-f"></dd>
168
- </dl>
169
- </fieldset>
170
- </form>
171
- ```
172
-
173
- #### Set number of columns a single input field takes up
174
-
175
- You can specify the number of columns an input will span using the `colspan-#` class on the `<dd>` element. The inputs are responsive and will shrink according to available space. Available numbered classes are `colspan-1` through `colspan-5`:
176
-
177
- ```html
178
- <form class="semanticForms">
179
- <fieldset>
180
- <dl>
181
- <dt><label for="input-a">Input A</label></dt>
182
- <!-- 1 column -->
183
- <dd class="colspan-1"><input type="text" id="input-a" name="input-a"></dd>
184
-
185
- <dt><label for="input-b">Input B</label></dt>
186
- <!-- 2 columns -->
187
- <dd class="colspan-2"><input type="text" id="input-b" name="input-b"></dd>
188
-
189
- <dt><label for="input-c">Input C</label></dt>
190
- <!-- 5 columns (max) -->
191
- <dd class="colspan-5"><input type="text" id="input-c" name="input-c"></dd>
192
- </dl>
193
- </fieldset>
194
- </form>
195
- ```
196
-
197
- `colspan-full` can also be used to force an input to take up the entire width of a form:
198
-
199
- ```html
200
- <form class="semanticForms">
201
- <fieldset>
202
- <dl>
203
- <dt><label for="input-a">Input A</label></dt>
204
- <!-- this spans 2 columns on row 1 -->
205
- <dd class="colspan-2"><input type="text" id="input-a" name="input-a"></dd>
206
-
207
- <dt><label for="input-b">Input B</label></dt>
208
- <!-- this spans the full width of row 2 -->
209
- <dd class="colspan-full"><input type="text" id="input-b" name="input-b"></dd>
210
-
211
- <!-- this spans 1 column on row 3 -->
212
- <dt><label for="input-c">Input C</label></dt>
213
- <dd><input type="text" id="input-c" name="input-c"></dd>
214
- </dl>
215
- </fieldset>
216
- </form>
217
- ```
218
-
219
- ##### Set number of columns a single input field takes up on the low flow (JavaScript disabled flow)
220
-
221
- To apply `colspan-#` styles to low flow (JavaScript disabled flow) form inputs, you will need to manually wrap your `<dt>` and `<dd>` elements in a `<div>`:
222
-
223
- ```html
224
- <form class="semanticForms">
225
- <fieldset>
226
- <dl>
227
- <div>
228
- <dt><label for="input-a">Input A</label></dt>
229
- <!-- this spans 2 columns on row 1 -->
230
- <dd class="colspan-2"><input type="text" id="input-a" name="input-a"></dd>
231
- </div>
232
- </dl>
233
- </fieldset>
234
- </form>
235
- ```
236
-
237
- ### Button groups
238
-
239
- You can align buttons side-by-side, or in left/right/center groups.
240
-
241
- #### Non-grouped example
242
-
243
- Nothing fancy here:
244
-
245
- ```html
246
- <button type="submit" name="submit">Non-grouped submit button</button>
247
- <button type="submit" name="submit">Another one</button>
248
- ```
249
-
250
- #### Button groups
251
-
252
- Driven by flexbox to intelligently align the buttons based on how many are in the group:
253
-
254
- ```html
255
- <!-- aligns left/right -->
256
- <menu>
257
- <li><button type="submit" name="submit">Button 1</button></li>
258
- <li><button type="submit" name="submit">Button 2</button></li>
259
- </menu>
260
-
261
- <!-- aligns left/center/right -->
262
- <menu>
263
- <li><button type="submit" name="submit">Button 1</button></li>
264
- <li><button type="submit" name="submit">Button 2</button></li>
265
- <li><button type="submit" name="submit">Button 3</button></li>
266
- </menu>
267
- ```
268
-
269
- ### Checkboxes and radio buttons
270
-
271
- Checkboxes and radio buttons need to follow the following markup structure:
272
-
273
- #### A single checkbox
274
-
275
- Not too different than other inputs:
276
-
277
- ```html
278
- <form class="semanticForms">
279
- <dl>
280
- <dt><label for="some_field_name">Single checkbox</label></dt>
281
- <dd><input type="checkbox" name="some_field_name" id="some_field_name"></dd>
282
- </dl>
283
- </form>
284
- ```
285
-
286
- #### Checkbox group
287
-
288
- ```html
289
- <form class="semanticForms">
290
- <dl>
291
- <dt><label data-for="some_field_name">Checkboxes:</label></dt>
292
- <dd class="checkboxes">
293
- <ul id="some_field_name_checkboxes">
294
- <li><input type="checkbox" name="some_field_name" id="some_field_name_checkboxes_one"> <label for="some_field_name_checkboxes_one">One</label></li>
295
- <li><input type="checkbox" name="some_field_name" id="some_field_name_checkboxes_two"> <label for="some_field_name_checkboxes_two">Two</label></li>
296
- <li><input type="checkbox" name="some_field_name" id="some_field_name_checkboxes_three"> <label for="some_field_name_checkboxes_three">Three</label></li>
297
- </ul>
298
- </dd>
299
- </dl>
300
- </form>
301
- ```
302
-
303
- #### Radio buttons
304
-
305
- ```html
306
- <form class="semanticForms">
307
- <dl>
308
- <dt><label data-for="some_field_name">Radios:</label></dt>
309
- <dd class="radios">
310
- <ul id="some_field_name">
311
- <li><input type="radio" name="some_field_name" id="r_one"> <label for="r_one">One</label></li>
312
- <li><input type="radio" name="some_field_name" id="r_two"> <label for="r_two">Two</label></li>
313
- <li><input type="radio" name="some_field_name" id="r_three"> <label for="r_three">Three</label></li>
314
- </ul>
315
- </dd>
316
- </dl>
317
- </form>
318
- ```
319
-
320
- ### Validation styles
321
-
322
- Inputs with the `required` attribute will result in a visual indicator (*) being added to its label. You can disable this indicator with the `data-no-asterisk` attribute on the label element:
323
-
324
- ```html
325
- <form class="semanticForms">
326
- <dl>
327
- <dt><label for="input" data-no-asterisk>Input label</label></dt>
328
- <dd><input type="text" name="input" id="input" required>
329
- </dl>
330
- </form>
331
- ```
332
-
333
- You can set a paragraph of text below a field to only appear when a field is invalid with the `data-invalid-text` attribute:
334
-
335
- ```html
336
- <form class="semanticForms">
337
- <dl>
338
- <dt><label for="password">Password label</label><dt>
339
- <dd>
340
- <input type="password" name="password" id="password" minlength="8">
341
- <p data-invalid-text>Password must be at least 8 characters long.</p>
342
- </dd>
343
- </dl>
344
- </form>
345
- ```
346
-
347
- You can adjust the tooltip text of the asterisk with the `data-asterisk-text` attribute:
348
-
349
- ```html
350
- <form class="semanticForms">
351
- <dl>
352
- <dt><label for="input" data-asterisk-text="This is a custom tooltip.">Input label</label></dt>
353
- <dd><input type="text" name="input" id="input" required>
354
- </dl>
355
- </form>
356
- ```
357
-
358
- ### Dark mode
359
-
360
- To set the dark mode, apply an additional class of `dark` to your `<form>` elements to force the dark mode.
361
-
362
- ### Low flow (JavaScript disabled) mode
363
-
364
- The low flow will be displayed if JS is disabled.
365
-
366
- You can also activate the low flow (JavaScript disabled) mode manually by adding the `lowFlow` class to your `<form>` element.
367
-
368
- The low-flow mode reverts the float label pattern to traditional labels and doesn't include other JS-exclusive enhancements, but preserves the other visual design enhancements driven purely by CSS.
369
-
370
- ## Contributing
371
-
372
- - Fork/clone this repo.
373
- - `npm ci`
374
- - Make your changes. If you want to alter the CSS, do the changes in the `.scss` files.
375
- - `npm run build`. The build step compiles the SCSS file into CSS.
376
- - You can also run `npm run watch` automatically compiles the CSS file after a change is detected in the SCSS file.
377
- - Test your changes by opening `semanticForms.html` in your browser.
378
- - If you want to test your work on an actual HTTP server, run `npm run dev` or `npm run d`, and then visit http://localhost:3000/test/semanticForms
379
- - Commit, push, open pull request.
1
+ See documentation [here](https://rooseveltframework.org/docs/semantic-forms/latest).