@epa-wg/custom-element 0.0.23 → 0.0.24
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/README.md +3 -3
- package/bin/xslDtd2Ide.mjs +1 -1
- package/custom-element.js +9 -1
- package/demo/form.html +2 -3
- package/ide/web-types-dce.json +1 -1
- package/ide/web-types-xsl.json +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -348,9 +348,9 @@ within template
|
|
|
348
348
|
[github-image]: https://cdnjs.cloudflare.com/ajax/libs/octicons/8.5.0/svg/mark-github.svg
|
|
349
349
|
[npm-image]: https://img.shields.io/npm/v/@epa-wg/custom-element.svg
|
|
350
350
|
[npm-url]: https://npmjs.org/package/@epa-wg/custom-element
|
|
351
|
-
[coverage-image]: https://unpkg.com/@epa-wg/custom-element-dist@0.0.
|
|
352
|
-
[coverage-url]: https://unpkg.com/@epa-wg/custom-element-dist@0.0.
|
|
353
|
-
[storybook-url]: https://unpkg.com/@epa-wg/custom-element-dist@0.0.
|
|
351
|
+
[coverage-image]: https://unpkg.com/@epa-wg/custom-element-dist@0.0.24/coverage/src/custom-element/coverage.svg
|
|
352
|
+
[coverage-url]: https://unpkg.com/@epa-wg/custom-element-dist@0.0.24/coverage/src/custom-element/index.html
|
|
353
|
+
[storybook-url]: https://unpkg.com/@epa-wg/custom-element-dist@0.0.24/storybook-static/index.html?path=/story/welcome--introduction
|
|
354
354
|
[sandbox-url]: https://stackblitz.com/github/EPA-WG/custom-element?file=index.html
|
|
355
355
|
[webcomponents-url]: https://www.webcomponents.org/element/@epa-wg/custom-element
|
|
356
356
|
[webcomponents-img]: https://img.shields.io/badge/webcomponents.org-published-blue.svg
|
package/bin/xslDtd2Ide.mjs
CHANGED
|
@@ -116,7 +116,7 @@ writeFileSync( '.././ide/customData-xsl.json', JSON.stringify( vsCode, undefined
|
|
|
116
116
|
const intelliJ = {
|
|
117
117
|
"$schema": "http://json.schemastore.org/web-types",
|
|
118
118
|
"name": "@epa-wg/custom-element",
|
|
119
|
-
"version": "0.0.
|
|
119
|
+
"version": "0.0.24",
|
|
120
120
|
"js-types-syntax": "typescript",
|
|
121
121
|
"description-markup": "markdown",
|
|
122
122
|
"contributions": {
|
package/custom-element.js
CHANGED
|
@@ -434,6 +434,14 @@ export function assureUnique(n, id=0)
|
|
|
434
434
|
e.childNodes.length && assureUnique(e)
|
|
435
435
|
}
|
|
436
436
|
}
|
|
437
|
+
export function appendByDceId(parent,e,k)
|
|
438
|
+
{
|
|
439
|
+
k = 1*k;
|
|
440
|
+
for( let n of parent.childNodes )
|
|
441
|
+
if( (n.dceId ?? n.getAttribute('data-dce-id')*1) > k )
|
|
442
|
+
return parent.insertBefore(e,n);
|
|
443
|
+
parent.append(e)
|
|
444
|
+
}
|
|
437
445
|
export function merge( parent, fromArr )
|
|
438
446
|
{
|
|
439
447
|
if(!fromArr.length)
|
|
@@ -461,7 +469,7 @@ export function merge( parent, fromArr )
|
|
|
461
469
|
}
|
|
462
470
|
delete id2old[ k ]
|
|
463
471
|
}else
|
|
464
|
-
parent
|
|
472
|
+
appendByDceId(parent,e,k)
|
|
465
473
|
}
|
|
466
474
|
for( let v of Object.values(id2old) )
|
|
467
475
|
v.remove();
|
package/demo/form.html
CHANGED
|
@@ -183,8 +183,8 @@
|
|
|
183
183
|
<ol>
|
|
184
184
|
<li> type in input field</li>
|
|
185
185
|
<li> delete input field content</li>
|
|
186
|
-
<li> observe the warning in string
|
|
187
|
-
<li> Click Next observe the system warning in dropdown
|
|
186
|
+
<li> observe the warning in string after input</li>
|
|
187
|
+
<li> Click Next observe the system warning in dropdown over input</li>
|
|
188
188
|
</ol>
|
|
189
189
|
<template>
|
|
190
190
|
<custom-element>
|
|
@@ -197,7 +197,6 @@
|
|
|
197
197
|
<var>{//username/@validation-message}</var>
|
|
198
198
|
</if>
|
|
199
199
|
<button>Next</button>
|
|
200
|
-
<p>{//email-form/@validation-message}</p>
|
|
201
200
|
</form>
|
|
202
201
|
</template>
|
|
203
202
|
</custom-element>
|
package/ide/web-types-dce.json
CHANGED
package/ide/web-types-xsl.json
CHANGED
package/package.json
CHANGED