@aurodesignsystem-dev/auro-formkit 0.0.0-pr1451.0 → 0.0.0-pr1452.0
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/components/checkbox/demo/api.md +221 -201
- package/components/checkbox/demo/api.min.js +1 -1
- package/components/checkbox/demo/index.md +23 -21
- package/components/checkbox/demo/index.min.js +1 -1
- package/components/checkbox/demo/keyboardBehavior.md +0 -0
- package/components/checkbox/demo/readme.md +35 -23
- package/components/checkbox/dist/index.js +1 -1
- package/components/checkbox/dist/registered.js +1 -1
- package/components/combobox/README.md +3 -13
- package/components/combobox/demo/api.html +0 -24
- package/components/combobox/demo/api.md +1685 -1613
- package/components/combobox/demo/api.min.js +1506 -1506
- package/components/combobox/demo/index.html +16 -49
- package/components/combobox/demo/index.js +2 -3
- package/components/combobox/demo/index.md +185 -861
- package/components/combobox/demo/index.min.js +1468 -1493
- package/components/combobox/demo/{keyboard-behavior.html → keyboardBehavior.html} +1 -2
- package/components/combobox/demo/keyboardBehavior.md +281 -0
- package/components/combobox/demo/readme.html +1 -25
- package/components/combobox/demo/readme.md +52 -50
- package/components/combobox/dist/index.js +3 -3
- package/components/combobox/dist/registered.js +3 -3
- package/components/counter/demo/api.md +819 -751
- package/components/counter/demo/api.min.js +2 -2
- package/components/counter/demo/index.md +39 -35
- package/components/counter/demo/index.min.js +2 -2
- package/components/counter/demo/keyboardBehavior.md +127 -0
- package/components/counter/demo/readme.md +51 -39
- package/components/counter/dist/index.js +2 -2
- package/components/counter/dist/registered.js +2 -2
- package/components/datepicker/demo/api.md +931 -827
- package/components/datepicker/demo/api.min.js +3 -3
- package/components/datepicker/demo/index.md +87 -79
- package/components/datepicker/demo/index.min.js +3 -3
- package/components/datepicker/demo/keyboardBehavior.md +19 -0
- package/components/datepicker/demo/readme.md +31 -19
- package/components/datepicker/dist/index.js +3 -3
- package/components/datepicker/dist/registered.js +3 -3
- package/components/dropdown/demo/api.md +851 -795
- package/components/dropdown/demo/api.min.js +1 -1
- package/components/dropdown/demo/index.md +155 -145
- package/components/dropdown/demo/index.min.js +1 -1
- package/components/dropdown/demo/keyboardBehavior.md +77 -0
- package/components/dropdown/demo/readme.md +51 -39
- package/components/dropdown/dist/index.js +1 -1
- package/components/dropdown/dist/registered.js +1 -1
- package/components/form/demo/api.md +179 -173
- package/components/form/demo/api.min.js +928 -928
- package/components/form/demo/index.md +33 -27
- package/components/form/demo/index.min.js +928 -928
- package/components/form/demo/keyboardBehavior.md +0 -0
- package/components/form/demo/readme.md +28 -14
- package/components/input/demo/api.md +664 -572
- package/components/input/demo/api.min.js +1 -1
- package/components/input/demo/index.md +99 -93
- package/components/input/demo/index.min.js +1 -1
- package/components/input/demo/keyboardBehavior.md +0 -0
- package/components/input/demo/readme.md +29 -17
- package/components/input/dist/index.js +1 -1
- package/components/input/dist/registered.js +1 -1
- package/components/menu/demo/api.md +786 -742
- package/components/menu/demo/api.min.js +1572 -1572
- package/components/menu/demo/index.md +37 -35
- package/components/menu/demo/index.min.js +1572 -1572
- package/components/menu/demo/keyboardBehavior.md +0 -0
- package/components/menu/demo/readme.md +35 -23
- package/components/menu/dist/auro-menu.context.d.ts +0 -1
- package/components/menu/dist/index.js +1607 -1607
- package/components/menu/dist/registered.js +1556 -1556
- package/components/radio/demo/api.md +350 -318
- package/components/radio/demo/api.min.js +1 -1
- package/components/radio/demo/index.md +29 -25
- package/components/radio/demo/index.min.js +1 -1
- package/components/radio/demo/keyboardBehavior.md +0 -0
- package/components/radio/demo/readme.md +33 -21
- package/components/radio/dist/index.js +1 -1
- package/components/radio/dist/registered.js +1 -1
- package/components/select/README.md +1 -12
- package/components/select/demo/api.md +1793 -1713
- package/components/select/demo/api.min.js +1505 -1505
- package/components/select/demo/index.html +37 -247
- package/components/select/demo/index.md +345 -225
- package/components/select/demo/index.min.js +1505 -1505
- package/components/select/demo/keyboardBehavior.md +245 -0
- package/components/select/demo/readme.md +46 -45
- package/components/select/dist/index.js +2 -2
- package/components/select/dist/registered.js +2 -2
- package/custom-elements.json +244 -244
- package/package.json +16 -2
- package/components/checkbox/demo/keyboard-behavior.md +0 -39
- package/components/combobox/demo/accessibility.html +0 -57
- package/components/combobox/demo/accessibility.md +0 -77
- package/components/combobox/demo/design.html +0 -83
- package/components/combobox/demo/design.md +0 -283
- package/components/combobox/demo/install.html +0 -84
- package/components/combobox/demo/install.js +0 -24
- package/components/combobox/demo/install.md +0 -100
- package/components/combobox/demo/install.min.js +0 -17991
- package/components/combobox/demo/keyboard-behavior.md +0 -276
- package/components/combobox/demo/layout.md +0 -112
- package/components/combobox/demo/styles.css +0 -141
- package/components/combobox/demo/voiceover.html +0 -66
- package/components/combobox/demo/voiceover.md +0 -118
- package/components/counter/demo/keyboard-behavior.md +0 -127
- package/components/datepicker/demo/keyboard-behavior.md +0 -19
- package/components/dropdown/demo/keyboard-behavior.md +0 -72
- package/components/form/demo/keyboard-behavior.md +0 -38
- package/components/input/demo/keyboard-behavior.md +0 -25
- package/components/menu/demo/keyboard-behavior.md +0 -18
- package/components/radio/demo/keyboard-behavior.md +0 -72
- package/components/select/demo/accessibility.html +0 -65
- package/components/select/demo/accessibility.md +0 -76
- package/components/select/demo/keyboard-behavior.md +0 -39
- package/components/select/demo/layout.html +0 -59
- package/components/select/demo/layout.md +0 -299
- package/components/select/demo/voiceover.html +0 -65
- package/components/select/demo/voiceover.md +0 -183
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<!--
|
|
2
|
-
THIS PAGE'S CONTENT SHOULD BE KEPT MINIMAL.
|
|
3
|
-
ONLY ADD EXAMPLES THAT ARE TRULY NECESSARY FOR THE INDEX PAGE — THE BASIC EXAMPLE IS USUALLY ENOUGH.
|
|
4
|
-
ALL OTHER EXAMPLES SHOULD GO IN THE API DOCUMENTATION.
|
|
2
|
+
THIS PAGE'S CONTENT SHOULD BE KEPT MINIMAL.
|
|
3
|
+
ONLY ADD EXAMPLES THAT ARE TRULY NECESSARY FOR THE INDEX PAGE — THE BASIC EXAMPLE IS USUALLY ENOUGH.
|
|
4
|
+
ALL OTHER EXAMPLES SHOULD GO IN THE API DOCUMENTATION.
|
|
5
5
|
-->
|
|
6
6
|
|
|
7
7
|
# Checkbox
|
|
@@ -26,28 +26,30 @@ The `<auro-checkbox>` element should be used in situations where users may:
|
|
|
26
26
|
### Basic
|
|
27
27
|
|
|
28
28
|
<div class="exampleWrapper">
|
|
29
|
-
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/basic.html) -->
|
|
30
|
-
<!-- The below content is automatically added from ./../apiExamples/basic.html -->
|
|
31
|
-
<auro-checkbox-group>
|
|
32
|
-
<span slot="legend">Form label goes here</span>
|
|
33
|
-
<auro-checkbox value="value1" name="basic" id="checkbox-basic1">Checkbox option</auro-checkbox>
|
|
34
|
-
<auro-checkbox value="value2" name="basic" id="checkbox-basic2" checked>Checkbox option</auro-checkbox>
|
|
35
|
-
<auro-checkbox value="value3" name="basic" id="checkbox-basic3">Checkbox option that has some extra text that should wrap when rendered in a narrow container</auro-checkbox>
|
|
36
|
-
<auro-checkbox value="value4" name="basic" id="checkbox-basic4">Checkbox option</auro-checkbox>
|
|
37
|
-
</auro-checkbox-group>
|
|
38
|
-
<!-- AURO-GENERATED-CONTENT:END -->
|
|
29
|
+
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./../apiExamples/basic.html) -->
|
|
30
|
+
<!-- The below content is automatically added from ./../apiExamples/basic.html -->
|
|
31
|
+
<auro-checkbox-group>
|
|
32
|
+
<span slot="legend">Form label goes here</span>
|
|
33
|
+
<auro-checkbox value="value1" name="basic" id="checkbox-basic1">Checkbox option</auro-checkbox>
|
|
34
|
+
<auro-checkbox value="value2" name="basic" id="checkbox-basic2" checked>Checkbox option</auro-checkbox>
|
|
35
|
+
<auro-checkbox value="value3" name="basic" id="checkbox-basic3">Checkbox option that has some extra text that should wrap when rendered in a narrow container</auro-checkbox>
|
|
36
|
+
<auro-checkbox value="value4" name="basic" id="checkbox-basic4">Checkbox option</auro-checkbox>
|
|
37
|
+
</auro-checkbox-group>
|
|
38
|
+
<!-- AURO-GENERATED-CONTENT:END -->
|
|
39
39
|
</div>
|
|
40
40
|
<auro-accordion alignRight>
|
|
41
|
-
<span slot="trigger">See code</span>
|
|
41
|
+
<span slot="trigger">See code</span>
|
|
42
42
|
<!-- AURO-GENERATED-CONTENT:START (CODE:src=./../apiExamples/basic.html) -->
|
|
43
43
|
<!-- The below code snippet is automatically added from ./../apiExamples/basic.html -->
|
|
44
44
|
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
45
|
+
```html
|
|
46
|
+
<auro-checkbox-group>
|
|
47
|
+
<span slot="legend">Form label goes here</span>
|
|
48
|
+
<auro-checkbox value="value1" name="basic" id="checkbox-basic1">Checkbox option</auro-checkbox>
|
|
49
|
+
<auro-checkbox value="value2" name="basic" id="checkbox-basic2" checked>Checkbox option</auro-checkbox>
|
|
50
|
+
<auro-checkbox value="value3" name="basic" id="checkbox-basic3">Checkbox option that has some extra text that should wrap when rendered in a narrow container</auro-checkbox>
|
|
51
|
+
<auro-checkbox value="value4" name="basic" id="checkbox-basic4">Checkbox option</auro-checkbox>
|
|
52
|
+
</auro-checkbox-group>
|
|
53
|
+
```
|
|
52
54
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
53
55
|
</auro-accordion>
|
|
@@ -1681,7 +1681,7 @@ class AuroHelpText extends i$2 {
|
|
|
1681
1681
|
}
|
|
1682
1682
|
}
|
|
1683
1683
|
|
|
1684
|
-
var formkitVersion = '
|
|
1684
|
+
var formkitVersion = '202604242248';
|
|
1685
1685
|
|
|
1686
1686
|
// Copyright (c) 2026 Alaska Airlines. All rights reserved. Licensed under the Apache-2.0 license
|
|
1687
1687
|
// See LICENSE in the project root for license information.
|
|
File without changes
|
|
@@ -45,7 +45,9 @@ The `<auro-checkbox>` element should be used in situations where users may:
|
|
|
45
45
|
|
|
46
46
|
#### NPM Installation
|
|
47
47
|
|
|
48
|
-
|
|
48
|
+
```shell
|
|
49
|
+
$ npm i @aurodesignsystem/auro-formkit
|
|
50
|
+
```
|
|
49
51
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
50
52
|
<!-- AURO-GENERATED-CONTENT:START (FILE:src=../../docs/templates/gettingStarted.md) -->
|
|
51
53
|
<!-- The below content is automatically added from ../../docs/templates/gettingStarted.md -->
|
|
@@ -54,11 +56,13 @@ The `<auro-checkbox>` element should be used in situations where users may:
|
|
|
54
56
|
|
|
55
57
|
When using TypeScript set `moduleResolution` to `bundler`, add the following to your `tsconfig.json`:
|
|
56
58
|
|
|
57
|
-
|
|
59
|
+
```json
|
|
60
|
+
{
|
|
58
61
|
"compilerOptions": {
|
|
59
62
|
"moduleResolution": "bundler"
|
|
60
63
|
}
|
|
61
|
-
}
|
|
64
|
+
}
|
|
65
|
+
```
|
|
62
66
|
|
|
63
67
|
This configuration enables proper module resolution for the component's TypeScript files.
|
|
64
68
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
@@ -69,7 +73,9 @@ This configuration enables proper module resolution for the component's TypeScri
|
|
|
69
73
|
<!-- The below content is automatically added from ../../docs/templates/bundleInstallDescription.md -->
|
|
70
74
|
In cases where the project is not able to process JS assets, there are pre-processed assets available for use. Legacy browsers such as IE11 are no longer supported.
|
|
71
75
|
|
|
72
|
-
|
|
76
|
+
```html
|
|
77
|
+
<script type="module" src="https://cdn.jsdelivr.net/npm/@aurodesignsystem/auro-formkit@latest/auro-checkbox/+esm"></script>
|
|
78
|
+
```
|
|
73
79
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
74
80
|
|
|
75
81
|
## Formkit Development
|
|
@@ -83,7 +89,9 @@ Running the `dev` command will open a `localhost` development server for all com
|
|
|
83
89
|
|
|
84
90
|
To only develop a single component, use the `--filter` flag:
|
|
85
91
|
|
|
86
|
-
|
|
92
|
+
```shell
|
|
93
|
+
npx turbo dev --filter=@aurodesignsystem/auro-input
|
|
94
|
+
```
|
|
87
95
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
88
96
|
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./docs/partials/customRegistration.md) -->
|
|
89
97
|
<!-- The below content is automatically added from ./docs/partials/customRegistration.md -->
|
|
@@ -98,33 +106,37 @@ However, if you need to load multiple versions of the same component on a single
|
|
|
98
106
|
|
|
99
107
|
You can do this by importing only the component class and using the `register(name)` method with a unique name:
|
|
100
108
|
|
|
101
|
-
|
|
109
|
+
```js
|
|
110
|
+
// Import the class only
|
|
102
111
|
import { AuroCheckbox, AuroCheckboxGroup } from '@aurodesignsystem/auro-formkit/auro-checkbox/class';
|
|
103
|
-
|
|
112
|
+
|
|
104
113
|
// Register with a custom name if desired
|
|
105
114
|
AuroCheckbox.register('custom-checkbox');
|
|
106
|
-
AuroCheckboxGroup.register('custom-checkbox-group')
|
|
115
|
+
AuroCheckboxGroup.register('custom-checkbox-group');
|
|
116
|
+
```
|
|
107
117
|
|
|
108
118
|
This will create a new custom element `<custom-checkbox>` and `<custom-checkbox-group>` that behaves exactly like `<auro-checkbox>` and `<auro-checkbox-group>`, allowing both to coexist on the same page without interfering with each other.
|
|
109
119
|
|
|
110
120
|
<div class="exampleWrapper exampleWrapper--flex">
|
|
111
|
-
<custom-checkbox-group>
|
|
112
|
-
<span slot="legend">Form label goes here</span>
|
|
113
|
-
<custom-checkbox value="value1" name="custom" id="checkbox-custom1">Custom checkbox option</custom-checkbox>
|
|
114
|
-
<custom-checkbox value="value2" name="custom" id="checkbox-custom2" checked>Custom checkbox option</custom-checkbox>
|
|
115
|
-
<custom-checkbox value="value3" name="custom" id="checkbox-custom3">Custom checkbox option</custom-checkbox>
|
|
116
|
-
<custom-checkbox value="value4" name="custom" id="checkbox-custom4">Custom checkbox option</custom-checkbox>
|
|
117
|
-
</custom-checkbox-group>
|
|
121
|
+
<custom-checkbox-group>
|
|
122
|
+
<span slot="legend">Form label goes here</span>
|
|
123
|
+
<custom-checkbox value="value1" name="custom" id="checkbox-custom1">Custom checkbox option</custom-checkbox>
|
|
124
|
+
<custom-checkbox value="value2" name="custom" id="checkbox-custom2" checked>Custom checkbox option</custom-checkbox>
|
|
125
|
+
<custom-checkbox value="value3" name="custom" id="checkbox-custom3">Custom checkbox option</custom-checkbox>
|
|
126
|
+
<custom-checkbox value="value4" name="custom" id="checkbox-custom4">Custom checkbox option</custom-checkbox>
|
|
127
|
+
</custom-checkbox-group>
|
|
118
128
|
</div>
|
|
119
129
|
<auro-accordion alignRight>
|
|
120
|
-
<span slot="trigger">See code</span>
|
|
130
|
+
<span slot="trigger">See code</span>
|
|
121
131
|
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
132
|
+
```html
|
|
133
|
+
<custom-checkbox-group>
|
|
134
|
+
<span slot="legend">Form label goes here</span>
|
|
135
|
+
<custom-checkbox value="value1" name="custom" id="checkbox-custom1">Custom checkbox option</custom-checkbox>
|
|
136
|
+
<custom-checkbox value="value2" name="custom" id="checkbox-custom2" checked>Custom checkbox option</custom-checkbox>
|
|
137
|
+
<custom-checkbox value="value3" name="custom" id="checkbox-custom3">Custom checkbox option</custom-checkbox>
|
|
138
|
+
<custom-checkbox value="value4" name="custom" id="checkbox-custom4">Custom checkbox option</custom-checkbox>
|
|
139
|
+
</custom-checkbox-group>
|
|
140
|
+
```
|
|
129
141
|
</auro-accordion>
|
|
130
142
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
@@ -1634,7 +1634,7 @@ class AuroHelpText extends LitElement {
|
|
|
1634
1634
|
}
|
|
1635
1635
|
}
|
|
1636
1636
|
|
|
1637
|
-
var formkitVersion = '
|
|
1637
|
+
var formkitVersion = '202604242248';
|
|
1638
1638
|
|
|
1639
1639
|
// Copyright (c) 2026 Alaska Airlines. All rights reserved. Licensed under the Apache-2.0 license
|
|
1640
1640
|
// See LICENSE in the project root for license information.
|
|
@@ -1634,7 +1634,7 @@ class AuroHelpText extends LitElement {
|
|
|
1634
1634
|
}
|
|
1635
1635
|
}
|
|
1636
1636
|
|
|
1637
|
-
var formkitVersion = '
|
|
1637
|
+
var formkitVersion = '202604242248';
|
|
1638
1638
|
|
|
1639
1639
|
// Copyright (c) 2026 Alaska Airlines. All rights reserved. Licensed under the Apache-2.0 license
|
|
1640
1640
|
// See LICENSE in the project root for license information.
|
|
@@ -21,19 +21,9 @@ The following sections are editable by making changes to the following files:
|
|
|
21
21
|
|
|
22
22
|
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./docs/partials/description.md) -->
|
|
23
23
|
<!-- The below content is automatically added from ./docs/partials/description.md -->
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
<li><strong>Suggestion (default)</strong> — The user may type any value. The menu provides suggestions but does not restrict input.</li>
|
|
28
|
-
<li><strong>Filter</strong> — The user must select from the menu. Typing filters the available options but does not set the component's value. The value is only set when a menu option is selected.</li>
|
|
29
|
-
</ul>
|
|
30
|
-
<p>Common use cases:</p>
|
|
31
|
-
<ul>
|
|
32
|
-
<li><strong>Airport or city search</strong> — Type a city name or airport code to filter a long list of destinations.</li>
|
|
33
|
-
<li><strong>Country or region selection</strong> — Quickly find and select from a large set of geographic options.</li>
|
|
34
|
-
<li><strong>Autocomplete fields</strong> — Provide type-ahead suggestions for form fields where the set of valid values is known.</li>
|
|
35
|
-
<li><strong>Search with suggestions</strong> — Offer recommended results while still allowing freeform input.</li>
|
|
36
|
-
</ul>
|
|
24
|
+
`<auro-combobox>` is the combination of [dropdown](http://auro.alaskaair.com/components/auro/dropdown), [input](http://auro.alaskaair.com/components/auro/input), and [menu](http://auro.alaskaair.com/components/auro/menu) and allows users to filter search results from a predefined list as they type. When the user starts typing in the text input, a dropdown of a menu shows up to display options that match the user’s search.
|
|
25
|
+
|
|
26
|
+
By default, `auro-combobox` behaves as a suggestion list. This means any value may be typed into the combobox and the menu list presented effectively provides sample or suggestion options. With the use of the `persistInput` attribute the `auro-combobox` behaves as a filter of menu options. In this mode. typing into the input field will execute the filter but will not set the `value` of the combobox. The combobox value is set by selecting a menu option. Clicking the `X` clear button in the input will remove the current value of the HTML5 input causing the menu filter to reset as well as remove the current value of the combobox.
|
|
37
27
|
<!-- AURO-GENERATED-CONTENT:END -->
|
|
38
28
|
<!-- AURO-GENERATED-CONTENT:START (FILE:src=./docs/partials/readmeAddlInfo.md) -->
|
|
39
29
|
<!-- The below content is automatically added from ./docs/partials/readmeAddlInfo.md -->
|
|
@@ -33,7 +33,6 @@
|
|
|
33
33
|
<!-- Demo Specific Styles -->
|
|
34
34
|
<link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/npm/@aurodesignsystem/webcorestylesheets@latest/dist/demoWrapper.css" />
|
|
35
35
|
<link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/npm/@aurodesignsystem/webcorestylesheets@latest/dist/elementDemoStyles.css" />
|
|
36
|
-
<link rel="stylesheet" type="text/css" href="./styles.css" />
|
|
37
36
|
</head>
|
|
38
37
|
<body class="auro-markdown">
|
|
39
38
|
<main></main>
|
|
@@ -47,30 +46,7 @@
|
|
|
47
46
|
const rawHtml = marked.parse(text);
|
|
48
47
|
document.querySelector('main').innerHTML = rawHtml;
|
|
49
48
|
Prism.highlightAll();
|
|
50
|
-
addCopyButtons();
|
|
51
49
|
});
|
|
52
|
-
|
|
53
|
-
function addCopyButtons() {
|
|
54
|
-
document.querySelectorAll('auro-accordion pre[class*="language-"]').forEach((pre) => {
|
|
55
|
-
const wrapper = document.createElement('div');
|
|
56
|
-
wrapper.className = 'pre-wrapper';
|
|
57
|
-
pre.parentNode.insertBefore(wrapper, pre);
|
|
58
|
-
wrapper.appendChild(pre);
|
|
59
|
-
const btn = document.createElement('button');
|
|
60
|
-
btn.className = 'copy-btn';
|
|
61
|
-
btn.textContent = 'Copy';
|
|
62
|
-
btn.addEventListener('click', () => {
|
|
63
|
-
const code = pre.querySelector('code');
|
|
64
|
-
const raw = code ? code.textContent : pre.textContent;
|
|
65
|
-
const text = raw.replace(/\u200B/g, '').replace(/^\n+/, '').replace(/\n+$/, '\n');
|
|
66
|
-
navigator.clipboard.writeText(text).then(() => {
|
|
67
|
-
btn.textContent = 'Copied!';
|
|
68
|
-
setTimeout(() => { btn.textContent = 'Copy'; }, 1500);
|
|
69
|
-
});
|
|
70
|
-
});
|
|
71
|
-
wrapper.appendChild(btn);
|
|
72
|
-
});
|
|
73
|
-
}
|
|
74
50
|
</script>
|
|
75
51
|
|
|
76
52
|
<!-- If additional elements are needed for the demo, add them here. -->
|