@public-ui/theme-default 2.0.0-rc.9 → 2.0.1
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/index.cjs +37 -63
- package/dist/index.d.ts +3 -1
- package/dist/index.mjs +37 -63
- package/package.json +10 -10
package/dist/index.cjs
CHANGED
|
@@ -301,7 +301,7 @@ var loglevel = {exports: {}};
|
|
|
301
301
|
}));
|
|
302
302
|
} (loglevel));
|
|
303
303
|
|
|
304
|
-
const
|
|
304
|
+
const N=(e,t)=>s=>s(e,t),P=(e,t)=>s=>s(e,t,{append:!1}),o=typeof window=="object"?window:typeof global=="object"?global:typeof self=="object"?self:{};const c=new Map,C=[],v=new Set,h=new Map,B=/--[^;]+/g,G=/:/;(typeof o.A11yUi!="object"||o.A11yUi===null)&&(o.A11yUi={CSS_STYLE_CACHE:h,HYDRATED_HISTORY:C,STYLING_TASK_QUEUE:c});const K=(e,t)=>{let s=t.match(B);if(Array.isArray(s)){s=s.filter(r=>G.test(r));const a=document.createElement("style");a.innerHTML=`.${e} {${s.join(";")}}`,document.querySelector("head")?.appendChild(a);}v.add(e);},d=(e,t)=>typeof o.A11yUi=="object"&&o.A11yUi!==null&&typeof o.A11yUi.Themes=="object"&&o.A11yUi.Themes!==null&&typeof o.A11yUi.Themes[e]=="object"&&o.A11yUi.Themes[e]!==null&&typeof o.A11yUi.Themes[e][t]=="string"?o.A11yUi.Themes[e][t].replace(/\r?\n/g,""):"",q=e=>{for(const t of Array.from(e.childNodes))if(t instanceof HTMLStyleElement&&t.tagName==="STYLE")e.removeChild(t);else break},F=(e,t)=>{try{const s=[];t.forEach(a=>{const r=new CSSStyleSheet;r.replaceSync(a),s.push(r);}),e.adoptedStyleSheets=s;}catch{t.reverse().forEach(s=>{const a=document.createElement("style");a.innerHTML=s,e.insertBefore(a,e.firstChild);});}},Q=(e,t,s)=>{if(s!==!1){const a=[...Array.from(e.childNodes).filter(n=>n instanceof HTMLStyleElement&&n.tagName==="STYLE")];let r;try{r=[...Array.from(e.adoptedStyleSheets)];}catch{r=[];}s?.mode==="before"?(a.reverse().forEach(n=>t.unshift(n.innerHTML)),r.reverse().forEach(n=>t.unshift(Array.from(n.cssRules).map(i=>i.cssText).join("")))):s?.mode==="after"&&(a.forEach(n=>t.push(n.innerHTML)),r.forEach(n=>t.push(Array.from(n.cssRules).map(i=>i.cssText).join(""))));}},L=(e,t,s)=>{const a=t.name||"default";let r;try{if(e.shadowRoot===null)throw new Error("ShadowRoot is null");r=e.shadowRoot;}catch{r=e;}if(h.get(a)?.has(e.tagName))M(e,r,h.get(a)?.get(e.tagName),s);else {const n=d(a,"PROPERTIES"),i=d(a,"GLOBAL"),H=d(a,e.tagName);v.has(a)===!1&&K(a,i);const m=[n,i,H];Q(r,m,t.encroachCss),t.loglevel==="debug"&&console.log(e.tagName,m),t.cache===!0&&(h.has(a)===!1&&h.set(a,new Map),h.get(a)?.set(e.tagName,m)),M(e,r,m,s);}},M=(e,t,s,a)=>{q(t),F(t,s),e.style.display=a;},$=e=>{e.loglevel==="debug"&&C.push({timestamp:Date.now(),numberOfTasks:c.size});},W=e=>{c.delete(e);},O=(e,t)=>{W(e),$(t);},X=e=>{for(const t of e)if(c.has(t.target)&&t.target.classList.contains("hydrated")){const{styleDisplay:s,themeDetails:a}=c.get(t.target);L(t.target,a,s),O(t.target,a);}};let f;try{f=new MutationObserver(X);}catch{f=null;}class te{constructor(t,s,a){this.createTheme=(r,n)=>P(r,n),this.createTranslation=(r,n)=>N(r,n),this.Prefix=t,this.Key=Object.getOwnPropertyNames(s),this.Tag=Object.getOwnPropertyNames(a);}}
|
|
305
305
|
|
|
306
306
|
var KeyEnum = /* @__PURE__ */ ((KeyEnum2) => {
|
|
307
307
|
KeyEnum2[KeyEnum2["error"] = 0] = "error";
|
|
@@ -382,7 +382,7 @@ var TagEnum = /* @__PURE__ */ ((TagEnum2) => {
|
|
|
382
382
|
return TagEnum2;
|
|
383
383
|
})(TagEnum || {});
|
|
384
384
|
|
|
385
|
-
const KoliBri = new
|
|
385
|
+
const KoliBri = new te("kol", KeyEnum, TagEnum);
|
|
386
386
|
|
|
387
387
|
const cssWithCustomLayerName = (layerName) => (input) => `@layer ${layerName} { ${input.join(``)} }`;
|
|
388
388
|
const css = (input) => cssWithCustomLayerName("kol-theme-component")(input);
|
|
@@ -406,6 +406,7 @@ const DEFAULT = KoliBri.createTheme("default", {
|
|
|
406
406
|
--color-mute-variant: var(--kolibri-color-mute-variant, #bec5c9);
|
|
407
407
|
}
|
|
408
408
|
:host {
|
|
409
|
+
background-color: transparent; /* Reset global background-color defined by components */
|
|
409
410
|
font-family: var(--font-family);
|
|
410
411
|
font-size: var(--font-size);
|
|
411
412
|
}
|
|
@@ -1367,29 +1368,29 @@ const DEFAULT = KoliBri.createTheme("default", {
|
|
|
1367
1368
|
}
|
|
1368
1369
|
`,
|
|
1369
1370
|
"KOL-HEADING": css`
|
|
1370
|
-
h1,
|
|
1371
|
-
h2,
|
|
1372
|
-
h3,
|
|
1373
|
-
h4,
|
|
1374
|
-
h5,
|
|
1375
|
-
h6 {
|
|
1371
|
+
.headline-h1,
|
|
1372
|
+
.headline-h2,
|
|
1373
|
+
.headline-h3,
|
|
1374
|
+
.headline-h4,
|
|
1375
|
+
.headline-h5,
|
|
1376
|
+
.headline-h6 {
|
|
1376
1377
|
color: inherit;
|
|
1377
1378
|
font-style: normal;
|
|
1378
1379
|
}
|
|
1379
|
-
h1,
|
|
1380
|
-
h2,
|
|
1381
|
-
h3 {
|
|
1380
|
+
.headline-h1,
|
|
1381
|
+
.headline-h2,
|
|
1382
|
+
.headline-h3 {
|
|
1382
1383
|
font-weight: 700;
|
|
1383
1384
|
}
|
|
1384
|
-
h1 {
|
|
1385
|
+
.headline-h1 {
|
|
1385
1386
|
font-size: 1.5rem;
|
|
1386
1387
|
line-height: 1.75rem;
|
|
1387
1388
|
}
|
|
1388
|
-
h2 {
|
|
1389
|
+
.headline-h2 {
|
|
1389
1390
|
font-size: 1.25rem;
|
|
1390
1391
|
line-height: 1.75rem;
|
|
1391
1392
|
}
|
|
1392
|
-
h3 {
|
|
1393
|
+
.headline-h3 {
|
|
1393
1394
|
font-size: 1.125rem;
|
|
1394
1395
|
line-height: 1.5rem;
|
|
1395
1396
|
}
|
|
@@ -1972,6 +1973,9 @@ const DEFAULT = KoliBri.createTheme("default", {
|
|
|
1972
1973
|
:host kol-input.button {
|
|
1973
1974
|
gap: 0.4rem 0;
|
|
1974
1975
|
}
|
|
1976
|
+
.checkbox-container {
|
|
1977
|
+
justify-content: flex-start;
|
|
1978
|
+
}
|
|
1975
1979
|
:host kol-input > div.input {
|
|
1976
1980
|
display: inherit;
|
|
1977
1981
|
min-height: var(--a11y-min-size);
|
|
@@ -2040,13 +2044,6 @@ const DEFAULT = KoliBri.createTheme("default", {
|
|
|
2040
2044
|
cursor: pointer;
|
|
2041
2045
|
transition: 0.5s;
|
|
2042
2046
|
}
|
|
2043
|
-
:host kol-input input[type='checkbox'].kol-disabled:before {
|
|
2044
|
-
cursor: not-allowed;
|
|
2045
|
-
}
|
|
2046
|
-
:host kol-input input[type='checkbox']:before {
|
|
2047
|
-
content: '';
|
|
2048
|
-
cursor: pointer;
|
|
2049
|
-
}
|
|
2050
2047
|
:host kol-input input[type='checkbox']:checked {
|
|
2051
2048
|
background-color: var(--color-primary);
|
|
2052
2049
|
border-color: var(--color-primary);
|
|
@@ -2057,51 +2054,23 @@ const DEFAULT = KoliBri.createTheme("default", {
|
|
|
2057
2054
|
min-width: calc(6 * 0.25rem);
|
|
2058
2055
|
width: calc(6 * 0.25rem);
|
|
2059
2056
|
}
|
|
2060
|
-
:host kol-input.default input[type='checkbox']:before {
|
|
2061
|
-
border-radius: 1.5em;
|
|
2062
|
-
background-color: transparent;
|
|
2063
|
-
display: block;
|
|
2064
|
-
height: calc(6 * 0.25rem);
|
|
2065
|
-
position: relative;
|
|
2066
|
-
width: calc(6 * 0.25rem);
|
|
2067
|
-
}
|
|
2068
|
-
:host kol-input.default input[type='checkbox']:checked:before {
|
|
2069
|
-
border-right-width: 3px;
|
|
2070
|
-
border-bottom-width: 3px;
|
|
2071
|
-
left: calc(1.5 * 0.25rem - 2px);
|
|
2072
|
-
top: calc(2.85 * 0.25rem - 2px);
|
|
2073
|
-
transform: rotate(40deg) translate(-50%, -50%);
|
|
2074
|
-
background-color: transparent;
|
|
2075
|
-
border-width: 0px 3px 3px 0px;
|
|
2076
|
-
border-color: white;
|
|
2077
|
-
border-radius: 1px;
|
|
2078
|
-
border-style: solid;
|
|
2079
|
-
height: calc(3 * 0.25rem);
|
|
2080
|
-
width: calc(1.5 * 0.25rem);
|
|
2081
|
-
}
|
|
2082
2057
|
:host kol-input.default input[type='checkbox']:indeterminate {
|
|
2083
2058
|
background-color: var(--color-primary);
|
|
2084
2059
|
}
|
|
2085
|
-
:host kol-input.default
|
|
2086
|
-
|
|
2087
|
-
|
|
2088
|
-
top: 0.6rem;
|
|
2089
|
-
left: 0.25rem;
|
|
2090
|
-
width: calc(3 * 0.25rem);
|
|
2091
|
-
transform: inherit;
|
|
2092
|
-
}
|
|
2093
|
-
:host kol-input.default input[type='checkbox']:checked:indeterminate:before {
|
|
2094
|
-
border-width: 0px 1px 1px 0px;
|
|
2060
|
+
:host kol-input.default .icon {
|
|
2061
|
+
color: var(--color-light);
|
|
2062
|
+
margin-left: 0.25rem;
|
|
2095
2063
|
}
|
|
2064
|
+
|
|
2096
2065
|
:host kol-input.switch input[type='checkbox'] {
|
|
2097
|
-
min-width: 3.5em;
|
|
2098
|
-
width: 3.5em;
|
|
2099
2066
|
background-color: var(--color-subtle);
|
|
2067
|
+
border-radius: 1.25em;
|
|
2100
2068
|
border-width: 0;
|
|
2069
|
+
display: block;
|
|
2101
2070
|
height: 1.5em;
|
|
2102
|
-
|
|
2103
|
-
display: inline-block;
|
|
2071
|
+
min-width: 3.5em;
|
|
2104
2072
|
position: relative;
|
|
2073
|
+
width: 3.5em;
|
|
2105
2074
|
}
|
|
2106
2075
|
:host kol-input.switch input[type='checkbox']:before {
|
|
2107
2076
|
width: 1.25em;
|
|
@@ -2128,17 +2097,24 @@ const DEFAULT = KoliBri.createTheme("default", {
|
|
|
2128
2097
|
left: 2px;
|
|
2129
2098
|
}
|
|
2130
2099
|
|
|
2131
|
-
|
|
2100
|
+
&.checked .icon {
|
|
2132
2101
|
transform: translate(2em, -50%);
|
|
2133
2102
|
}
|
|
2134
2103
|
|
|
2135
|
-
|
|
2104
|
+
&.indeterminate .icon {
|
|
2136
2105
|
transform: translate(1em, -50%);
|
|
2137
2106
|
}
|
|
2138
2107
|
}
|
|
2139
2108
|
:host .disabled {
|
|
2140
2109
|
opacity: 0.33;
|
|
2141
2110
|
}
|
|
2111
|
+
.button:focus-within {
|
|
2112
|
+
border-radius: var(--border-radius);
|
|
2113
|
+
outline-color: var(--color-primary-variant);
|
|
2114
|
+
outline-offset: 2px;
|
|
2115
|
+
outline-style: solid;
|
|
2116
|
+
outline-width: calc(var(--border-width) * 2);
|
|
2117
|
+
}
|
|
2142
2118
|
`,
|
|
2143
2119
|
"KOL-INPUT-RADIO": css`
|
|
2144
2120
|
label {
|
|
@@ -2222,7 +2198,7 @@ const DEFAULT = KoliBri.createTheme("default", {
|
|
|
2222
2198
|
cursor: not-allowed;
|
|
2223
2199
|
background-color: var(--color-mute-variant);
|
|
2224
2200
|
}
|
|
2225
|
-
|
|
2201
|
+
kol-alert.error {
|
|
2226
2202
|
order: 1;
|
|
2227
2203
|
}
|
|
2228
2204
|
fieldset legend {
|
|
@@ -2233,12 +2209,10 @@ const DEFAULT = KoliBri.createTheme("default", {
|
|
|
2233
2209
|
order: 3;
|
|
2234
2210
|
}
|
|
2235
2211
|
fieldset.error {
|
|
2236
|
-
padding-left: 1rem;
|
|
2237
2212
|
border-left: 3px solid var(--color-danger);
|
|
2238
|
-
}
|
|
2239
|
-
fieldset kol-alert#error {
|
|
2240
2213
|
color: var(--color-danger);
|
|
2241
2214
|
font-weight: 700;
|
|
2215
|
+
padding-left: 1rem;
|
|
2242
2216
|
}
|
|
2243
2217
|
fieldset.error input:focus,
|
|
2244
2218
|
fieldset.error select:focus,
|
package/dist/index.d.ts
CHANGED
|
@@ -47,6 +47,8 @@ declare const DEFAULT: (patch: (name: string, map: {
|
|
|
47
47
|
"KOL-TOAST-CONTAINER"?: string | undefined;
|
|
48
48
|
"KOL-TOOLBAR"?: string | undefined;
|
|
49
49
|
"KOL-TOOLTIP"?: string | undefined;
|
|
50
|
-
}
|
|
50
|
+
}, options?: {
|
|
51
|
+
append?: boolean | undefined;
|
|
52
|
+
} | undefined) => string) => string;
|
|
51
53
|
|
|
52
54
|
export { DEFAULT };
|
package/dist/index.mjs
CHANGED
|
@@ -299,7 +299,7 @@ var loglevel = {exports: {}};
|
|
|
299
299
|
}));
|
|
300
300
|
} (loglevel));
|
|
301
301
|
|
|
302
|
-
const
|
|
302
|
+
const N=(e,t)=>s=>s(e,t),P=(e,t)=>s=>s(e,t,{append:!1}),o=typeof window=="object"?window:typeof global=="object"?global:typeof self=="object"?self:{};const c=new Map,C=[],v=new Set,h=new Map,B=/--[^;]+/g,G=/:/;(typeof o.A11yUi!="object"||o.A11yUi===null)&&(o.A11yUi={CSS_STYLE_CACHE:h,HYDRATED_HISTORY:C,STYLING_TASK_QUEUE:c});const K=(e,t)=>{let s=t.match(B);if(Array.isArray(s)){s=s.filter(r=>G.test(r));const a=document.createElement("style");a.innerHTML=`.${e} {${s.join(";")}}`,document.querySelector("head")?.appendChild(a);}v.add(e);},d=(e,t)=>typeof o.A11yUi=="object"&&o.A11yUi!==null&&typeof o.A11yUi.Themes=="object"&&o.A11yUi.Themes!==null&&typeof o.A11yUi.Themes[e]=="object"&&o.A11yUi.Themes[e]!==null&&typeof o.A11yUi.Themes[e][t]=="string"?o.A11yUi.Themes[e][t].replace(/\r?\n/g,""):"",q=e=>{for(const t of Array.from(e.childNodes))if(t instanceof HTMLStyleElement&&t.tagName==="STYLE")e.removeChild(t);else break},F=(e,t)=>{try{const s=[];t.forEach(a=>{const r=new CSSStyleSheet;r.replaceSync(a),s.push(r);}),e.adoptedStyleSheets=s;}catch{t.reverse().forEach(s=>{const a=document.createElement("style");a.innerHTML=s,e.insertBefore(a,e.firstChild);});}},Q=(e,t,s)=>{if(s!==!1){const a=[...Array.from(e.childNodes).filter(n=>n instanceof HTMLStyleElement&&n.tagName==="STYLE")];let r;try{r=[...Array.from(e.adoptedStyleSheets)];}catch{r=[];}s?.mode==="before"?(a.reverse().forEach(n=>t.unshift(n.innerHTML)),r.reverse().forEach(n=>t.unshift(Array.from(n.cssRules).map(i=>i.cssText).join("")))):s?.mode==="after"&&(a.forEach(n=>t.push(n.innerHTML)),r.forEach(n=>t.push(Array.from(n.cssRules).map(i=>i.cssText).join(""))));}},L=(e,t,s)=>{const a=t.name||"default";let r;try{if(e.shadowRoot===null)throw new Error("ShadowRoot is null");r=e.shadowRoot;}catch{r=e;}if(h.get(a)?.has(e.tagName))M(e,r,h.get(a)?.get(e.tagName),s);else {const n=d(a,"PROPERTIES"),i=d(a,"GLOBAL"),H=d(a,e.tagName);v.has(a)===!1&&K(a,i);const m=[n,i,H];Q(r,m,t.encroachCss),t.loglevel==="debug"&&console.log(e.tagName,m),t.cache===!0&&(h.has(a)===!1&&h.set(a,new Map),h.get(a)?.set(e.tagName,m)),M(e,r,m,s);}},M=(e,t,s,a)=>{q(t),F(t,s),e.style.display=a;},$=e=>{e.loglevel==="debug"&&C.push({timestamp:Date.now(),numberOfTasks:c.size});},W=e=>{c.delete(e);},O=(e,t)=>{W(e),$(t);},X=e=>{for(const t of e)if(c.has(t.target)&&t.target.classList.contains("hydrated")){const{styleDisplay:s,themeDetails:a}=c.get(t.target);L(t.target,a,s),O(t.target,a);}};let f;try{f=new MutationObserver(X);}catch{f=null;}class te{constructor(t,s,a){this.createTheme=(r,n)=>P(r,n),this.createTranslation=(r,n)=>N(r,n),this.Prefix=t,this.Key=Object.getOwnPropertyNames(s),this.Tag=Object.getOwnPropertyNames(a);}}
|
|
303
303
|
|
|
304
304
|
var KeyEnum = /* @__PURE__ */ ((KeyEnum2) => {
|
|
305
305
|
KeyEnum2[KeyEnum2["error"] = 0] = "error";
|
|
@@ -380,7 +380,7 @@ var TagEnum = /* @__PURE__ */ ((TagEnum2) => {
|
|
|
380
380
|
return TagEnum2;
|
|
381
381
|
})(TagEnum || {});
|
|
382
382
|
|
|
383
|
-
const KoliBri = new
|
|
383
|
+
const KoliBri = new te("kol", KeyEnum, TagEnum);
|
|
384
384
|
|
|
385
385
|
const cssWithCustomLayerName = (layerName) => (input) => `@layer ${layerName} { ${input.join(``)} }`;
|
|
386
386
|
const css = (input) => cssWithCustomLayerName("kol-theme-component")(input);
|
|
@@ -404,6 +404,7 @@ const DEFAULT = KoliBri.createTheme("default", {
|
|
|
404
404
|
--color-mute-variant: var(--kolibri-color-mute-variant, #bec5c9);
|
|
405
405
|
}
|
|
406
406
|
:host {
|
|
407
|
+
background-color: transparent; /* Reset global background-color defined by components */
|
|
407
408
|
font-family: var(--font-family);
|
|
408
409
|
font-size: var(--font-size);
|
|
409
410
|
}
|
|
@@ -1365,29 +1366,29 @@ const DEFAULT = KoliBri.createTheme("default", {
|
|
|
1365
1366
|
}
|
|
1366
1367
|
`,
|
|
1367
1368
|
"KOL-HEADING": css`
|
|
1368
|
-
h1,
|
|
1369
|
-
h2,
|
|
1370
|
-
h3,
|
|
1371
|
-
h4,
|
|
1372
|
-
h5,
|
|
1373
|
-
h6 {
|
|
1369
|
+
.headline-h1,
|
|
1370
|
+
.headline-h2,
|
|
1371
|
+
.headline-h3,
|
|
1372
|
+
.headline-h4,
|
|
1373
|
+
.headline-h5,
|
|
1374
|
+
.headline-h6 {
|
|
1374
1375
|
color: inherit;
|
|
1375
1376
|
font-style: normal;
|
|
1376
1377
|
}
|
|
1377
|
-
h1,
|
|
1378
|
-
h2,
|
|
1379
|
-
h3 {
|
|
1378
|
+
.headline-h1,
|
|
1379
|
+
.headline-h2,
|
|
1380
|
+
.headline-h3 {
|
|
1380
1381
|
font-weight: 700;
|
|
1381
1382
|
}
|
|
1382
|
-
h1 {
|
|
1383
|
+
.headline-h1 {
|
|
1383
1384
|
font-size: 1.5rem;
|
|
1384
1385
|
line-height: 1.75rem;
|
|
1385
1386
|
}
|
|
1386
|
-
h2 {
|
|
1387
|
+
.headline-h2 {
|
|
1387
1388
|
font-size: 1.25rem;
|
|
1388
1389
|
line-height: 1.75rem;
|
|
1389
1390
|
}
|
|
1390
|
-
h3 {
|
|
1391
|
+
.headline-h3 {
|
|
1391
1392
|
font-size: 1.125rem;
|
|
1392
1393
|
line-height: 1.5rem;
|
|
1393
1394
|
}
|
|
@@ -1970,6 +1971,9 @@ const DEFAULT = KoliBri.createTheme("default", {
|
|
|
1970
1971
|
:host kol-input.button {
|
|
1971
1972
|
gap: 0.4rem 0;
|
|
1972
1973
|
}
|
|
1974
|
+
.checkbox-container {
|
|
1975
|
+
justify-content: flex-start;
|
|
1976
|
+
}
|
|
1973
1977
|
:host kol-input > div.input {
|
|
1974
1978
|
display: inherit;
|
|
1975
1979
|
min-height: var(--a11y-min-size);
|
|
@@ -2038,13 +2042,6 @@ const DEFAULT = KoliBri.createTheme("default", {
|
|
|
2038
2042
|
cursor: pointer;
|
|
2039
2043
|
transition: 0.5s;
|
|
2040
2044
|
}
|
|
2041
|
-
:host kol-input input[type='checkbox'].kol-disabled:before {
|
|
2042
|
-
cursor: not-allowed;
|
|
2043
|
-
}
|
|
2044
|
-
:host kol-input input[type='checkbox']:before {
|
|
2045
|
-
content: '';
|
|
2046
|
-
cursor: pointer;
|
|
2047
|
-
}
|
|
2048
2045
|
:host kol-input input[type='checkbox']:checked {
|
|
2049
2046
|
background-color: var(--color-primary);
|
|
2050
2047
|
border-color: var(--color-primary);
|
|
@@ -2055,51 +2052,23 @@ const DEFAULT = KoliBri.createTheme("default", {
|
|
|
2055
2052
|
min-width: calc(6 * 0.25rem);
|
|
2056
2053
|
width: calc(6 * 0.25rem);
|
|
2057
2054
|
}
|
|
2058
|
-
:host kol-input.default input[type='checkbox']:before {
|
|
2059
|
-
border-radius: 1.5em;
|
|
2060
|
-
background-color: transparent;
|
|
2061
|
-
display: block;
|
|
2062
|
-
height: calc(6 * 0.25rem);
|
|
2063
|
-
position: relative;
|
|
2064
|
-
width: calc(6 * 0.25rem);
|
|
2065
|
-
}
|
|
2066
|
-
:host kol-input.default input[type='checkbox']:checked:before {
|
|
2067
|
-
border-right-width: 3px;
|
|
2068
|
-
border-bottom-width: 3px;
|
|
2069
|
-
left: calc(1.5 * 0.25rem - 2px);
|
|
2070
|
-
top: calc(2.85 * 0.25rem - 2px);
|
|
2071
|
-
transform: rotate(40deg) translate(-50%, -50%);
|
|
2072
|
-
background-color: transparent;
|
|
2073
|
-
border-width: 0px 3px 3px 0px;
|
|
2074
|
-
border-color: white;
|
|
2075
|
-
border-radius: 1px;
|
|
2076
|
-
border-style: solid;
|
|
2077
|
-
height: calc(3 * 0.25rem);
|
|
2078
|
-
width: calc(1.5 * 0.25rem);
|
|
2079
|
-
}
|
|
2080
2055
|
:host kol-input.default input[type='checkbox']:indeterminate {
|
|
2081
2056
|
background-color: var(--color-primary);
|
|
2082
2057
|
}
|
|
2083
|
-
:host kol-input.default
|
|
2084
|
-
|
|
2085
|
-
|
|
2086
|
-
top: 0.6rem;
|
|
2087
|
-
left: 0.25rem;
|
|
2088
|
-
width: calc(3 * 0.25rem);
|
|
2089
|
-
transform: inherit;
|
|
2090
|
-
}
|
|
2091
|
-
:host kol-input.default input[type='checkbox']:checked:indeterminate:before {
|
|
2092
|
-
border-width: 0px 1px 1px 0px;
|
|
2058
|
+
:host kol-input.default .icon {
|
|
2059
|
+
color: var(--color-light);
|
|
2060
|
+
margin-left: 0.25rem;
|
|
2093
2061
|
}
|
|
2062
|
+
|
|
2094
2063
|
:host kol-input.switch input[type='checkbox'] {
|
|
2095
|
-
min-width: 3.5em;
|
|
2096
|
-
width: 3.5em;
|
|
2097
2064
|
background-color: var(--color-subtle);
|
|
2065
|
+
border-radius: 1.25em;
|
|
2098
2066
|
border-width: 0;
|
|
2067
|
+
display: block;
|
|
2099
2068
|
height: 1.5em;
|
|
2100
|
-
|
|
2101
|
-
display: inline-block;
|
|
2069
|
+
min-width: 3.5em;
|
|
2102
2070
|
position: relative;
|
|
2071
|
+
width: 3.5em;
|
|
2103
2072
|
}
|
|
2104
2073
|
:host kol-input.switch input[type='checkbox']:before {
|
|
2105
2074
|
width: 1.25em;
|
|
@@ -2126,17 +2095,24 @@ const DEFAULT = KoliBri.createTheme("default", {
|
|
|
2126
2095
|
left: 2px;
|
|
2127
2096
|
}
|
|
2128
2097
|
|
|
2129
|
-
|
|
2098
|
+
&.checked .icon {
|
|
2130
2099
|
transform: translate(2em, -50%);
|
|
2131
2100
|
}
|
|
2132
2101
|
|
|
2133
|
-
|
|
2102
|
+
&.indeterminate .icon {
|
|
2134
2103
|
transform: translate(1em, -50%);
|
|
2135
2104
|
}
|
|
2136
2105
|
}
|
|
2137
2106
|
:host .disabled {
|
|
2138
2107
|
opacity: 0.33;
|
|
2139
2108
|
}
|
|
2109
|
+
.button:focus-within {
|
|
2110
|
+
border-radius: var(--border-radius);
|
|
2111
|
+
outline-color: var(--color-primary-variant);
|
|
2112
|
+
outline-offset: 2px;
|
|
2113
|
+
outline-style: solid;
|
|
2114
|
+
outline-width: calc(var(--border-width) * 2);
|
|
2115
|
+
}
|
|
2140
2116
|
`,
|
|
2141
2117
|
"KOL-INPUT-RADIO": css`
|
|
2142
2118
|
label {
|
|
@@ -2220,7 +2196,7 @@ const DEFAULT = KoliBri.createTheme("default", {
|
|
|
2220
2196
|
cursor: not-allowed;
|
|
2221
2197
|
background-color: var(--color-mute-variant);
|
|
2222
2198
|
}
|
|
2223
|
-
|
|
2199
|
+
kol-alert.error {
|
|
2224
2200
|
order: 1;
|
|
2225
2201
|
}
|
|
2226
2202
|
fieldset legend {
|
|
@@ -2231,12 +2207,10 @@ const DEFAULT = KoliBri.createTheme("default", {
|
|
|
2231
2207
|
order: 3;
|
|
2232
2208
|
}
|
|
2233
2209
|
fieldset.error {
|
|
2234
|
-
padding-left: 1rem;
|
|
2235
2210
|
border-left: 3px solid var(--color-danger);
|
|
2236
|
-
}
|
|
2237
|
-
fieldset kol-alert#error {
|
|
2238
2211
|
color: var(--color-danger);
|
|
2239
2212
|
font-weight: 700;
|
|
2213
|
+
padding-left: 1rem;
|
|
2240
2214
|
}
|
|
2241
2215
|
fieldset.error input:focus,
|
|
2242
2216
|
fieldset.error select:focus,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@public-ui/theme-default",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.1",
|
|
4
4
|
"license": "EUPL-1.2",
|
|
5
5
|
"homepage": "https://public-ui.github.io",
|
|
6
6
|
"repository": "https://github.com/public-ui/kolibri",
|
|
@@ -38,18 +38,18 @@
|
|
|
38
38
|
"wcag"
|
|
39
39
|
],
|
|
40
40
|
"devDependencies": {
|
|
41
|
-
"@public-ui/schema": "2.0.
|
|
42
|
-
"@public-ui/visual-tests": "2.0.
|
|
43
|
-
"@types/node": "ts5.
|
|
44
|
-
"@typescript-eslint/eslint-plugin": "6.
|
|
45
|
-
"@typescript-eslint/parser": "6.
|
|
46
|
-
"eslint": "8.
|
|
41
|
+
"@public-ui/schema": "2.0.1",
|
|
42
|
+
"@public-ui/visual-tests": "2.0.1",
|
|
43
|
+
"@types/node": "ts5.3",
|
|
44
|
+
"@typescript-eslint/eslint-plugin": "6.14.0",
|
|
45
|
+
"@typescript-eslint/parser": "6.14.0",
|
|
46
|
+
"eslint": "8.56.0",
|
|
47
47
|
"eslint-plugin-no-loops": "0.3.0",
|
|
48
|
-
"typescript": "5.
|
|
48
|
+
"typescript": "5.3.3",
|
|
49
49
|
"unbuild": "1.2.1"
|
|
50
50
|
},
|
|
51
51
|
"peerDependencies": {
|
|
52
|
-
"@public-ui/components": "2.0.
|
|
52
|
+
"@public-ui/components": "2.0.1"
|
|
53
53
|
},
|
|
54
54
|
"sideEffects": false,
|
|
55
55
|
"type": "module",
|
|
@@ -72,7 +72,7 @@
|
|
|
72
72
|
"depcheck": "depcheck --ignore-bin-package --skip-missing --ignores=@types/*",
|
|
73
73
|
"format": "prettier --check src",
|
|
74
74
|
"lint": "eslint src && tsc --noemit",
|
|
75
|
-
"test": "THEME_MODULE=src/index THEME_EXPORT=DEFAULT kolibri-visual-test
|
|
75
|
+
"test": "THEME_MODULE=src/index THEME_EXPORT=DEFAULT kolibri-visual-test",
|
|
76
76
|
"test-update": "THEME_MODULE=src/index THEME_EXPORT=DEFAULT kolibri-visual-test --update-snapshots theme-snapshots.spec.js"
|
|
77
77
|
}
|
|
78
78
|
}
|