@youcan/celeste 0.6.9 → 0.6.10
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/celeste.css
CHANGED
|
@@ -1843,7 +1843,7 @@ to {
|
|
|
1843
1843
|
}
|
|
1844
1844
|
.celeste-dropdown-item .celeste-dropdown-item-header-lg .celeste-dropdown-item-label[data-v-a0a634ce] {
|
|
1845
1845
|
font-weight: var(--font-weights-display-0);
|
|
1846
|
-
}.celeste-text-input-wrapper[data-v-
|
|
1846
|
+
}.celeste-text-input-wrapper[data-v-1dfd5779] {
|
|
1847
1847
|
display: flex;
|
|
1848
1848
|
box-sizing: border-box;
|
|
1849
1849
|
align-items: center;
|
|
@@ -1862,28 +1862,28 @@ to {
|
|
|
1862
1862
|
font: var(--paragraph-sm);
|
|
1863
1863
|
gap: var(--input-gap);
|
|
1864
1864
|
}
|
|
1865
|
-
.celeste-text-input-wrapper[size=xs][data-v-
|
|
1865
|
+
.celeste-text-input-wrapper[size=xs][data-v-1dfd5779] {
|
|
1866
1866
|
--input-gap: 8px;
|
|
1867
1867
|
--input-height: 32px;
|
|
1868
1868
|
--input-radius: var(--radius-8);
|
|
1869
1869
|
--input-padding: calc(var(--spacing-8) - var(--spacing-2));
|
|
1870
1870
|
}
|
|
1871
|
-
.celeste-text-input-wrapper[size=sm][data-v-
|
|
1871
|
+
.celeste-text-input-wrapper[size=sm][data-v-1dfd5779] {
|
|
1872
1872
|
--input-gap: 6px;
|
|
1873
1873
|
--input-height: 36px;
|
|
1874
1874
|
--input-radius: var(--radius-8);
|
|
1875
1875
|
--input-padding: var(--spacing-8);
|
|
1876
1876
|
}
|
|
1877
|
-
.celeste-text-input-wrapper[size=md][data-v-
|
|
1877
|
+
.celeste-text-input-wrapper[size=md][data-v-1dfd5779] {
|
|
1878
1878
|
--input-gap: 6px;
|
|
1879
1879
|
--input-height: 40px;
|
|
1880
1880
|
--input-radius: var(--radius-10);
|
|
1881
1881
|
--input-padding: var(--spacing-10);
|
|
1882
1882
|
}
|
|
1883
|
-
.celeste-text-input-wrapper[has-error=true][data-v-
|
|
1883
|
+
.celeste-text-input-wrapper[has-error=true][data-v-1dfd5779] {
|
|
1884
1884
|
border-color: var(--color-state-error-base);
|
|
1885
1885
|
}
|
|
1886
|
-
.celeste-text-input-wrapper .celeste-text-input[data-v-
|
|
1886
|
+
.celeste-text-input-wrapper .celeste-text-input[data-v-1dfd5779] {
|
|
1887
1887
|
width: 100%;
|
|
1888
1888
|
height: 100%;
|
|
1889
1889
|
padding: 0;
|
|
@@ -1893,90 +1893,90 @@ to {
|
|
|
1893
1893
|
color: inherit;
|
|
1894
1894
|
font: inherit;
|
|
1895
1895
|
}
|
|
1896
|
-
.celeste-text-input-wrapper .celeste-text-input[data-v-
|
|
1896
|
+
.celeste-text-input-wrapper .celeste-text-input[data-v-1dfd5779]::-moz-placeholder {
|
|
1897
1897
|
-moz-transition: color var(--animation-fast) ease-out;
|
|
1898
1898
|
transition: color var(--animation-fast) ease-out;
|
|
1899
1899
|
color: var(--color-text-soft-400);
|
|
1900
1900
|
}
|
|
1901
|
-
.celeste-text-input-wrapper .celeste-text-input[data-v-
|
|
1901
|
+
.celeste-text-input-wrapper .celeste-text-input[data-v-1dfd5779]::placeholder {
|
|
1902
1902
|
transition: color var(--animation-fast) ease-out;
|
|
1903
1903
|
color: var(--color-text-soft-400);
|
|
1904
1904
|
}
|
|
1905
|
-
.celeste-text-input-wrapper[data-v-
|
|
1905
|
+
.celeste-text-input-wrapper[data-v-1dfd5779]:has(.celeste-text-input:focus) {
|
|
1906
1906
|
border-color: var(--color-stroke-strong-950);
|
|
1907
1907
|
outline-color: var(--color-stroke-soft-200);
|
|
1908
1908
|
}
|
|
1909
|
-
.celeste-text-input-wrapper:has(.celeste-text-input:focus)[has-error=true][data-v-
|
|
1909
|
+
.celeste-text-input-wrapper:has(.celeste-text-input:focus)[has-error=true][data-v-1dfd5779] {
|
|
1910
1910
|
border-color: var(--color-state-error-base);
|
|
1911
1911
|
outline-color: var(--color-state-error-lighter);
|
|
1912
1912
|
}
|
|
1913
|
-
.celeste-text-input-wrapper[data-v-
|
|
1913
|
+
.celeste-text-input-wrapper[data-v-1dfd5779]:has(.celeste-text-input:disabled) {
|
|
1914
1914
|
border-color: transparent;
|
|
1915
1915
|
background-color: var(--color-bg-weak-50);
|
|
1916
1916
|
box-shadow: none;
|
|
1917
1917
|
color: var(--color-text-disabled-300);
|
|
1918
1918
|
pointer-events: none;
|
|
1919
1919
|
}
|
|
1920
|
-
.celeste-text-input-wrapper:has(.celeste-text-input:disabled) .celeste-text-input[data-v-
|
|
1920
|
+
.celeste-text-input-wrapper:has(.celeste-text-input:disabled) .celeste-text-input[data-v-1dfd5779]::-moz-placeholder {
|
|
1921
1921
|
color: currentcolor;
|
|
1922
1922
|
}
|
|
1923
|
-
.celeste-text-input-wrapper:has(.celeste-text-input:disabled) .celeste-text-input[data-v-
|
|
1923
|
+
.celeste-text-input-wrapper:has(.celeste-text-input:disabled) .celeste-text-input[data-v-1dfd5779]::placeholder {
|
|
1924
1924
|
color: currentcolor;
|
|
1925
1925
|
}
|
|
1926
|
-
.celeste-text-input-wrapper[data-v-
|
|
1926
|
+
.celeste-text-input-wrapper[data-v-1dfd5779]:has(.celeste-text-input:disabled) .celeste-text-input-icon {
|
|
1927
1927
|
color: var(--color-icon-disabled-300);
|
|
1928
1928
|
}
|
|
1929
|
-
.celeste-text-input-wrapper[data-v-
|
|
1929
|
+
.celeste-text-input-wrapper[data-v-1dfd5779]:has(.celeste-text-input:disabled) .celeste-text-input-affix, .celeste-text-input-wrapper[data-v-1dfd5779]:has(.celeste-text-input:disabled) .celeste-text-input-button {
|
|
1930
1930
|
background-color: var(--color-bg-weak-50) !important;
|
|
1931
1931
|
color: var(--color-text-disabled-300);
|
|
1932
1932
|
}
|
|
1933
|
-
.celeste-text-input-wrapper[data-v-
|
|
1933
|
+
.celeste-text-input-wrapper[data-v-1dfd5779]:has(.celeste-text-input-button, .celeste-text-input-affix[inline=false][askbd=false]) {
|
|
1934
1934
|
gap: var(--spacing-0);
|
|
1935
1935
|
padding-inline-end: var(--spacing-0);
|
|
1936
1936
|
}
|
|
1937
|
-
.celeste-text-input-wrapper:has(.celeste-text-input-button, .celeste-text-input-affix[inline=false][askbd=false]):has(.celeste-text-input-button[inline=false], .celeste-text-input-affix[variant=suffix]) .celeste-text-input[data-v-
|
|
1937
|
+
.celeste-text-input-wrapper:has(.celeste-text-input-button, .celeste-text-input-affix[inline=false][askbd=false]):has(.celeste-text-input-button[inline=false], .celeste-text-input-affix[variant=suffix]) .celeste-text-input[data-v-1dfd5779] {
|
|
1938
1938
|
padding-inline-end: var(--input-padding);
|
|
1939
1939
|
border-inline-end: 1px solid var(--color-stroke-soft-200);
|
|
1940
1940
|
}
|
|
1941
|
-
.celeste-text-input-wrapper[data-v-
|
|
1941
|
+
.celeste-text-input-wrapper[data-v-1dfd5779]:has(.celeste-text-input-button, .celeste-text-input-affix[inline=false][askbd=false]):has(.celeste-text-input-affix[variant=prefix]) {
|
|
1942
1942
|
padding-inline: var(--spacing-0) var(--input-padding);
|
|
1943
1943
|
}
|
|
1944
|
-
.celeste-text-input-wrapper:has(.celeste-text-input-button, .celeste-text-input-affix[inline=false][askbd=false]):has(.celeste-text-input-affix[variant=prefix]) .celeste-text-input[data-v-
|
|
1944
|
+
.celeste-text-input-wrapper:has(.celeste-text-input-button, .celeste-text-input-affix[inline=false][askbd=false]):has(.celeste-text-input-affix[variant=prefix]) .celeste-text-input[data-v-1dfd5779] {
|
|
1945
1945
|
padding-inline-start: var(--input-padding);
|
|
1946
1946
|
border-inline-start: 1px solid var(--color-stroke-soft-200);
|
|
1947
1947
|
}
|
|
1948
|
-
.celeste-text-input-wrapper[data-v-
|
|
1948
|
+
.celeste-text-input-wrapper[data-v-1dfd5779]:has(.celeste-text-input-button, .celeste-text-input-affix[inline=false][askbd=false]) .celeste-text-input-icon[position=start] {
|
|
1949
1949
|
margin-inline-end: var(--input-gap);
|
|
1950
1950
|
}
|
|
1951
|
-
.celeste-text-input-wrapper[data-v-
|
|
1951
|
+
.celeste-text-input-wrapper[data-v-1dfd5779]:has(.celeste-text-input-button, .celeste-text-input-affix[inline=false][askbd=false]) .celeste-text-input-icon[position=end] {
|
|
1952
1952
|
margin-inline-start: var(--input-gap);
|
|
1953
1953
|
}
|
|
1954
|
-
.celeste-text-input-wrapper[data-v-
|
|
1954
|
+
.celeste-text-input-wrapper[data-v-1dfd5779]:has(.celeste-text-input:hover:not(:focus, :disabled)) {
|
|
1955
1955
|
/* stylelint-disable-next-line no-descending-specificity */
|
|
1956
1956
|
}
|
|
1957
|
-
.celeste-text-input-wrapper[data-v-
|
|
1957
|
+
.celeste-text-input-wrapper[data-v-1dfd5779]:has(.celeste-text-input:hover:not(:focus, :disabled)):not(:has(.celeste-text-input-button, .celeste-text-input-affix)) {
|
|
1958
1958
|
border-color: transparent;
|
|
1959
1959
|
background-color: var(--color-bg-weak-50);
|
|
1960
1960
|
}
|
|
1961
|
-
.celeste-text-input-wrapper[data-v-
|
|
1961
|
+
.celeste-text-input-wrapper[data-v-1dfd5779]:has(.celeste-text-input:hover:not(:focus, :disabled)):has(.celeste-text-input-button:not(:hover), .celeste-text-input-affix:not(:hover)) {
|
|
1962
1962
|
background-color: var(--color-bg-weak-50);
|
|
1963
1963
|
}
|
|
1964
|
-
.celeste-text-input-wrapper:has(.celeste-text-input:hover:not(:focus, :disabled)):not(:has(.celeste-text-input-button:hover)) .celeste-text-input[data-v-
|
|
1964
|
+
.celeste-text-input-wrapper:has(.celeste-text-input:hover:not(:focus, :disabled)):not(:has(.celeste-text-input-button:hover)) .celeste-text-input[data-v-1dfd5779]::-moz-placeholder {
|
|
1965
1965
|
color: var(--color-text-sub-600);
|
|
1966
1966
|
}
|
|
1967
|
-
.celeste-text-input-wrapper:has(.celeste-text-input:hover:not(:focus, :disabled)):not(:has(.celeste-text-input-button:hover)) .celeste-text-input[data-v-
|
|
1967
|
+
.celeste-text-input-wrapper:has(.celeste-text-input:hover:not(:focus, :disabled)):not(:has(.celeste-text-input-button:hover)) .celeste-text-input[data-v-1dfd5779]::placeholder {
|
|
1968
1968
|
color: var(--color-text-sub-600);
|
|
1969
1969
|
}
|
|
1970
|
-
.celeste-text-input-wrapper[data-v-
|
|
1970
|
+
.celeste-text-input-wrapper[data-v-1dfd5779]:has(.celeste-text-input:-moz-placeholder:not(:disabled)) {
|
|
1971
1971
|
/* stylelint-disable-next-line no-descending-specificity */
|
|
1972
1972
|
}
|
|
1973
|
-
.celeste-text-input-wrapper[data-v-
|
|
1973
|
+
.celeste-text-input-wrapper[data-v-1dfd5779]:has(.celeste-text-input:placeholder-shown:not(:disabled)) {
|
|
1974
1974
|
/* stylelint-disable-next-line no-descending-specificity */
|
|
1975
1975
|
}
|
|
1976
|
-
.celeste-text-input-wrapper[data-v-
|
|
1976
|
+
.celeste-text-input-wrapper[data-v-1dfd5779]:has(.celeste-text-input:-moz-placeholder:not(:disabled)) .celeste-text-input-icon, .celeste-text-input-wrapper[data-v-1dfd5779]:has(.celeste-text-input:-moz-placeholder:not(:disabled)) .celeste-text-input-affix {
|
|
1977
1977
|
color: var(--color-text-soft-400);
|
|
1978
1978
|
}
|
|
1979
|
-
.celeste-text-input-wrapper[data-v-
|
|
1979
|
+
.celeste-text-input-wrapper[data-v-1dfd5779]:has(.celeste-text-input:placeholder-shown:not(:disabled)) .celeste-text-input-icon, .celeste-text-input-wrapper[data-v-1dfd5779]:has(.celeste-text-input:placeholder-shown:not(:disabled)) .celeste-text-input-affix {
|
|
1980
1980
|
color: var(--color-text-soft-400);
|
|
1981
1981
|
}[data-v-2cc18da8] {
|
|
1982
1982
|
box-sizing: border-box;
|
package/dist/cjs/text-input.js
CHANGED
|
@@ -22,20 +22,20 @@ const _sfc_main = /* @__PURE__ */ Mo.defineComponent({
|
|
|
22
22
|
return Mo.openBlock(), Mo.createElementBlock("label", {
|
|
23
23
|
size: _ctx.size,
|
|
24
24
|
"has-error": _ctx.hasError,
|
|
25
|
-
class: "celeste-text-input-wrapper"
|
|
25
|
+
class: Mo.normalizeClass(Mo.unref(clsx.clsx)("celeste-text-input-wrapper", props.class))
|
|
26
26
|
}, [
|
|
27
27
|
Mo.withDirectives(Mo.createElementVNode("input", Mo.mergeProps({
|
|
28
28
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => modelValue.value = $event)
|
|
29
29
|
}, _ctx.$attrs, {
|
|
30
30
|
type: _ctx.type,
|
|
31
|
-
class:
|
|
31
|
+
class: "celeste-text-input"
|
|
32
32
|
}), null, 16, _hoisted_2), [
|
|
33
33
|
[Mo.vModelDynamic, modelValue.value]
|
|
34
34
|
]),
|
|
35
35
|
Mo.renderSlot(_ctx.$slots, "default", {}, void 0, true)
|
|
36
|
-
],
|
|
36
|
+
], 10, _hoisted_1);
|
|
37
37
|
};
|
|
38
38
|
}
|
|
39
39
|
});
|
|
40
|
-
const TextInput = /* @__PURE__ */ _pluginVue_exportHelper._export_sfc(_sfc_main, [["__scopeId", "data-v-
|
|
40
|
+
const TextInput = /* @__PURE__ */ _pluginVue_exportHelper._export_sfc(_sfc_main, [["__scopeId", "data-v-1dfd5779"]]);
|
|
41
41
|
module.exports = TextInput;
|
package/dist/es/text-input.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent, mergeModels, useModel, openBlock, createElementBlock, withDirectives, createElementVNode, mergeProps,
|
|
1
|
+
import { defineComponent, mergeModels, useModel, openBlock, createElementBlock, normalizeClass, unref, withDirectives, createElementVNode, mergeProps, vModelDynamic, renderSlot } from "vue";
|
|
2
2
|
import { c as clsx } from "./chunks/clsx.js";
|
|
3
3
|
import { _ as _export_sfc } from "./chunks/_plugin-vue_export-helper.js";
|
|
4
4
|
const _hoisted_1 = ["size", "has-error"];
|
|
@@ -21,22 +21,22 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
21
21
|
return openBlock(), createElementBlock("label", {
|
|
22
22
|
size: _ctx.size,
|
|
23
23
|
"has-error": _ctx.hasError,
|
|
24
|
-
class: "celeste-text-input-wrapper"
|
|
24
|
+
class: normalizeClass(unref(clsx)("celeste-text-input-wrapper", props.class))
|
|
25
25
|
}, [
|
|
26
26
|
withDirectives(createElementVNode("input", mergeProps({
|
|
27
27
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => modelValue.value = $event)
|
|
28
28
|
}, _ctx.$attrs, {
|
|
29
29
|
type: _ctx.type,
|
|
30
|
-
class:
|
|
30
|
+
class: "celeste-text-input"
|
|
31
31
|
}), null, 16, _hoisted_2), [
|
|
32
32
|
[vModelDynamic, modelValue.value]
|
|
33
33
|
]),
|
|
34
34
|
renderSlot(_ctx.$slots, "default", {}, void 0, true)
|
|
35
|
-
],
|
|
35
|
+
], 10, _hoisted_1);
|
|
36
36
|
};
|
|
37
37
|
}
|
|
38
38
|
});
|
|
39
|
-
const TextInput = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-
|
|
39
|
+
const TextInput = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-1dfd5779"]]);
|
|
40
40
|
export {
|
|
41
41
|
TextInput as default
|
|
42
42
|
};
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@youcan/celeste",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.6.
|
|
4
|
+
"version": "0.6.10",
|
|
5
5
|
"author": "YouCan <tech@youcan.shop>",
|
|
6
6
|
"keywords": [
|
|
7
7
|
"youcan",
|
|
@@ -32,8 +32,8 @@
|
|
|
32
32
|
"clsx": "^2.1.1",
|
|
33
33
|
"radix-vue": "^1.9.12",
|
|
34
34
|
"tinycolor2": "^1.6.0",
|
|
35
|
-
"@youcan/celeste-icons": "0.6.
|
|
36
|
-
"@youcan/celeste-tokens": "0.6.
|
|
35
|
+
"@youcan/celeste-icons": "0.6.10",
|
|
36
|
+
"@youcan/celeste-tokens": "0.6.10"
|
|
37
37
|
},
|
|
38
38
|
"devDependencies": {
|
|
39
39
|
"@chromatic-com/storybook": "^4.0.0",
|
|
@@ -23,13 +23,13 @@ export interface TextInputProps extends /* @vue-ignore */ InputHTMLAttributes {
|
|
|
23
23
|
<label
|
|
24
24
|
:size="size"
|
|
25
25
|
:has-error="hasError"
|
|
26
|
-
class="celeste-text-input-wrapper"
|
|
26
|
+
:class="clsx('celeste-text-input-wrapper', props.class)"
|
|
27
27
|
>
|
|
28
28
|
<input
|
|
29
29
|
v-model="modelValue"
|
|
30
30
|
v-bind="$attrs"
|
|
31
31
|
:type="type"
|
|
32
|
-
|
|
32
|
+
class="celeste-text-input"
|
|
33
33
|
>
|
|
34
34
|
<slot />
|
|
35
35
|
</label>
|