@neovici/cosmoz-input 5.7.0 → 6.0.0-beta.2
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/dist/cosmoz-input.js +1 -0
- package/dist/cosmoz-textarea.js +9 -1
- package/dist/cosmoz-toggle.js +1 -1
- package/dist/render.js +2 -2
- package/dist/styles.js +2 -2
- package/package.json +1 -5
package/dist/cosmoz-input.js
CHANGED
package/dist/cosmoz-textarea.js
CHANGED
|
@@ -7,7 +7,15 @@ import { attributes, render } from './render';
|
|
|
7
7
|
import { styles } from './styles';
|
|
8
8
|
import { useAutoHeight } from './use-auto-height';
|
|
9
9
|
import { useInput } from './use-input';
|
|
10
|
-
const observedAttributes = [
|
|
10
|
+
const observedAttributes = [
|
|
11
|
+
'rows',
|
|
12
|
+
'placeholder',
|
|
13
|
+
'label',
|
|
14
|
+
'hint',
|
|
15
|
+
'error-message',
|
|
16
|
+
'required',
|
|
17
|
+
...attributes,
|
|
18
|
+
];
|
|
11
19
|
export const Textarea = (host) => {
|
|
12
20
|
const { autocomplete, value, placeholder, readonly, disabled, rows, cols, maxlength, } = host, { onChange, onFocus, onInput, onRef } = useInput(host);
|
|
13
21
|
useAutoHeight(host);
|
package/dist/cosmoz-toggle.js
CHANGED
package/dist/render.js
CHANGED
|
@@ -15,9 +15,9 @@ export const render = (control, { hint, label, invalid, errorMessage, compact, r
|
|
|
15
15
|
${control}
|
|
16
16
|
</div>
|
|
17
17
|
<!-- compact: tooltip always visible, red icon when invalid -->
|
|
18
|
-
${when(invalid, () => html `<cosmoz-tooltip
|
|
18
|
+
${when(compact && invalid && errorMessage, () => html `<cosmoz-tooltip
|
|
19
19
|
placement="top"
|
|
20
|
-
description=${
|
|
20
|
+
description=${errorMessage}
|
|
21
21
|
delay="300"
|
|
22
22
|
>
|
|
23
23
|
${infoCircleIcon({ width: '16px', height: '16px' })}
|
package/dist/styles.js
CHANGED
|
@@ -48,7 +48,7 @@ export const styles = css `
|
|
|
48
48
|
}
|
|
49
49
|
|
|
50
50
|
.wrap:has(#input:focus) {
|
|
51
|
-
box-shadow:
|
|
51
|
+
box-shadow: var(--cz-focus-ring);
|
|
52
52
|
}
|
|
53
53
|
|
|
54
54
|
:host([invalid]) .wrap {
|
|
@@ -56,7 +56,7 @@ export const styles = css `
|
|
|
56
56
|
}
|
|
57
57
|
|
|
58
58
|
:host([invalid]) .wrap:has(#input:focus) {
|
|
59
|
-
box-shadow:
|
|
59
|
+
box-shadow: var(--cz-focus-ring-error);
|
|
60
60
|
}
|
|
61
61
|
|
|
62
62
|
.control {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@neovici/cosmoz-input",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "6.0.0-beta.2",
|
|
4
4
|
"description": "A input web component",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"lit-html",
|
|
@@ -43,10 +43,6 @@
|
|
|
43
43
|
"@semantic-release/npm",
|
|
44
44
|
"@semantic-release/git"
|
|
45
45
|
],
|
|
46
|
-
"branches": [
|
|
47
|
-
"master",
|
|
48
|
-
"next"
|
|
49
|
-
],
|
|
50
46
|
"preset": "conventionalcommits"
|
|
51
47
|
},
|
|
52
48
|
"publishConfig": {
|