@progress/kendo-react-common 14.5.0-develop.7 → 14.5.0-develop.9
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/cdn/js/kendo-react-common.js +1 -1
- package/icons/BaseIconProps.d.ts +0 -2
- package/icons/Icon.js +1 -1
- package/icons/Icon.mjs +11 -13
- package/icons/SvgIcon.js +1 -1
- package/icons/SvgIcon.mjs +0 -2
- package/icons/models/theme-color.d.ts +1 -3
- package/package.json +7 -2
- package/theme.js +1 -1
- package/theme.mjs +4 -2
- package/typography/Typography.js +1 -1
- package/typography/Typography.mjs +6 -8
- package/typography/TypographyProps.d.ts +1 -3
- package/unstyled/buttons.d.ts +2 -0
- package/unstyled/buttons.js +1 -1
- package/unstyled/buttons.mjs +39 -38
- package/unstyled/icons.d.ts +2 -4
- package/unstyled/icons.js +1 -1
- package/unstyled/icons.mjs +10 -11
- package/unstyled/json-classes.js +1 -1
- package/unstyled/json-classes.mjs +13 -15
package/icons/Icon.js
CHANGED
|
@@ -6,4 +6,4 @@
|
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
8
|
"use client";
|
|
9
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const x=require("react"),r=require("prop-types"),z=require("../classNames.js"),I=require("./constants.js"),N=require("./utils.js"),P=require("../hooks/useMouse.js");function S(t){const n=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const s in t)if(s!=="default"){const o=Object.getOwnPropertyDescriptor(t,s);Object.defineProperty(n,s,o.get?o:{enumerable:!0,get:()=>t[s]})}}return n.default=t,Object.freeze(n)}const e=S(x),i=e.forwardRef((t,n)=>{const{className:s,name:o,themeColor:l,size:u,flip:f,style:g,id:b,tabIndex:y,...h}=t,c=e.useRef(null),m=e.useRef(null);e.useImperativeHandle(c,()=>({element:m.current})),e.useImperativeHandle(n,()=>c.current);const p=e.useMemo(()=>u||d.size,[u]),a=e.useMemo(()=>f||d.flip,[f]),O=e.useMemo(()=>z.classNames("k-icon","k-font-icon",o&&N.toIconClass(o),{[`k-color-${l}`]:l,"k-flip-h":a==="horizontal"||a==="both","k-flip-v":a==="vertical"||a==="both"},I.SIZE_CLASSES[p],s),[o,l,p,a,s]),v=P.useMouse(t,c);return e.createElement("span",{ref:m,...h,...v,className:O,id:b,tabIndex:y,style:g,role:"presentation"})});i.propTypes={style:r.object,classNames:r.string,name:r.string,themeColor:r.oneOf(["inherit","primary","secondary","tertiary","info","success","error","warning","
|
|
9
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const x=require("react"),r=require("prop-types"),z=require("../classNames.js"),I=require("./constants.js"),N=require("./utils.js"),P=require("../hooks/useMouse.js");function S(t){const n=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const s in t)if(s!=="default"){const o=Object.getOwnPropertyDescriptor(t,s);Object.defineProperty(n,s,o.get?o:{enumerable:!0,get:()=>t[s]})}}return n.default=t,Object.freeze(n)}const e=S(x),i=e.forwardRef((t,n)=>{const{className:s,name:o,themeColor:l,size:u,flip:f,style:g,id:b,tabIndex:y,...h}=t,c=e.useRef(null),m=e.useRef(null);e.useImperativeHandle(c,()=>({element:m.current})),e.useImperativeHandle(n,()=>c.current);const p=e.useMemo(()=>u||d.size,[u]),a=e.useMemo(()=>f||d.flip,[f]),O=e.useMemo(()=>z.classNames("k-icon","k-font-icon",o&&N.toIconClass(o),{[`k-color-${l}`]:l,"k-flip-h":a==="horizontal"||a==="both","k-flip-v":a==="vertical"||a==="both"},I.SIZE_CLASSES[p],s),[o,l,p,a,s]),v=P.useMouse(t,c);return e.createElement("span",{ref:m,...h,...v,className:O,id:b,tabIndex:y,style:g,role:"presentation"})});i.propTypes={style:r.object,classNames:r.string,name:r.string,themeColor:r.oneOf(["inherit","primary","secondary","tertiary","info","success","error","warning","inverse"]),size:r.oneOf(["default","xsmall","small","medium","large","xlarge","xxlarge","xxxlarge"]),flip:r.oneOf(["default","horizontal","vertical","both"])};const d={size:"default",flip:"default"};i.displayName="KendoIcon";exports.Icon=i;
|
package/icons/Icon.mjs
CHANGED
|
@@ -8,30 +8,30 @@
|
|
|
8
8
|
"use client";
|
|
9
9
|
import * as e from "react";
|
|
10
10
|
import o from "prop-types";
|
|
11
|
-
import { classNames as
|
|
12
|
-
import { SIZE_CLASSES as
|
|
13
|
-
import { toIconClass as
|
|
14
|
-
import { useMouse as
|
|
11
|
+
import { classNames as v } from "../classNames.mjs";
|
|
12
|
+
import { SIZE_CLASSES as N } from "./constants.mjs";
|
|
13
|
+
import { toIconClass as b } from "./utils.mjs";
|
|
14
|
+
import { useMouse as k } from "../hooks/useMouse.mjs";
|
|
15
15
|
const u = e.forwardRef((l, d) => {
|
|
16
|
-
const { className: n, name: s, themeColor: t, size: i, flip: m, style: h, id:
|
|
16
|
+
const { className: n, name: s, themeColor: t, size: i, flip: m, style: h, id: x, tabIndex: g, ...y } = l, a = e.useRef(null), f = e.useRef(null);
|
|
17
17
|
e.useImperativeHandle(a, () => ({
|
|
18
18
|
element: f.current
|
|
19
19
|
})), e.useImperativeHandle(d, () => a.current);
|
|
20
20
|
const c = e.useMemo(() => i || p.size, [i]), r = e.useMemo(() => m || p.flip, [m]), z = e.useMemo(
|
|
21
|
-
() =>
|
|
21
|
+
() => v(
|
|
22
22
|
"k-icon",
|
|
23
23
|
"k-font-icon",
|
|
24
|
-
s &&
|
|
24
|
+
s && b(s),
|
|
25
25
|
{
|
|
26
26
|
[`k-color-${t}`]: t,
|
|
27
27
|
"k-flip-h": r === "horizontal" || r === "both",
|
|
28
28
|
"k-flip-v": r === "vertical" || r === "both"
|
|
29
29
|
},
|
|
30
|
-
|
|
30
|
+
N[c],
|
|
31
31
|
n
|
|
32
32
|
),
|
|
33
33
|
[s, t, c, r, n]
|
|
34
|
-
), I =
|
|
34
|
+
), I = k(l, a);
|
|
35
35
|
return /* @__PURE__ */ e.createElement(
|
|
36
36
|
"span",
|
|
37
37
|
{
|
|
@@ -39,8 +39,8 @@ const u = e.forwardRef((l, d) => {
|
|
|
39
39
|
...y,
|
|
40
40
|
...I,
|
|
41
41
|
className: z,
|
|
42
|
-
id:
|
|
43
|
-
tabIndex:
|
|
42
|
+
id: x,
|
|
43
|
+
tabIndex: g,
|
|
44
44
|
style: h,
|
|
45
45
|
role: "presentation"
|
|
46
46
|
}
|
|
@@ -59,8 +59,6 @@ u.propTypes = {
|
|
|
59
59
|
"success",
|
|
60
60
|
"error",
|
|
61
61
|
"warning",
|
|
62
|
-
"dark",
|
|
63
|
-
"light",
|
|
64
62
|
"inverse"
|
|
65
63
|
]),
|
|
66
64
|
size: o.oneOf(["default", "xsmall", "small", "medium", "large", "xlarge", "xxlarge", "xxxlarge"]),
|
package/icons/SvgIcon.js
CHANGED
|
@@ -6,4 +6,4 @@
|
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
8
|
"use client";
|
|
9
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const q=require("react"),i=require("prop-types"),S=require("../classNames.js"),M=require("../unstyled/icons.js"),H=require("../unstyled/unstyled-context.js");function R(e){const l=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const s in e)if(s!=="default"){const r=Object.getOwnPropertyDescriptor(e,s);Object.defineProperty(l,s,r.get?r:{enumerable:!0,get:()=>e[s]})}}return l.default=e,Object.freeze(l)}const t=R(q),m=t.forwardRef((e,l)=>{const{children:s,className:r,svgClassName:N,icon:n,flip:f,id:p,tabIndex:z,size:g,style:a,svgStyle:I,themeColor:u,viewBox:v,name:_,onClick:P,...O}=e,w=t.useRef(null),y=H.useUnstyled(),h=y&&y.uSvgIcon;t.useImperativeHandle(l,()=>({element:w.current}));const b=t.useMemo(()=>n?n.name:c.icon,[n]),d=t.useMemo(()=>n?n.content:void 0,[n]),x=t.useMemo(()=>g||c.size,[g]),o=t.useMemo(()=>f||c.flip,[f]),C=t.useMemo(()=>v||c.viewBox,[v]),j=t.useMemo(()=>S.classNames(M.uSvgIcon.wrapper({c:h,iconNameProp:b,themeColor:u,flipH:o==="horizontal"||o==="both",flipV:o==="vertical"||o==="both",size:x}),r),[h,b,u,o,x,r]),B=t.useMemo(()=>e.width&&e.height?{width:e.width,height:e.height,...a}:e.width?{width:e.width,height:e.width,...a}:e.height?{width:e.height,height:e.height,...a}:{...a},[e.width,e.height,a]),T=t.useMemo(()=>d?{__html:d}:void 0,[d]);return t.createElement("span",{className:S.classNames(M.uSvgIcon.svg({c:h,themeColor:u,flipH:o==="horizontal"||o==="both",flipV:o==="vertical"||o==="both"}),j),style:B,ref:w,onClick:P,"aria-hidden":!0},t.createElement("svg",{id:p,className:N,style:I,"aria-hidden":!0,tabIndex:z,focusable:!1,xmlns:"http://www.w3.org/2000/svg",viewBox:n?n.viewBox:C,dangerouslySetInnerHTML:T,...O},n?void 0:s))});m.propTypes={style:i.object,classNames:i.string,children:i.any,icon:i.object,themeColor:i.oneOf(["inherit","primary","secondary","tertiary","info","success","error","warning","
|
|
9
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const q=require("react"),i=require("prop-types"),S=require("../classNames.js"),M=require("../unstyled/icons.js"),H=require("../unstyled/unstyled-context.js");function R(e){const l=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const s in e)if(s!=="default"){const r=Object.getOwnPropertyDescriptor(e,s);Object.defineProperty(l,s,r.get?r:{enumerable:!0,get:()=>e[s]})}}return l.default=e,Object.freeze(l)}const t=R(q),m=t.forwardRef((e,l)=>{const{children:s,className:r,svgClassName:N,icon:n,flip:f,id:p,tabIndex:z,size:g,style:a,svgStyle:I,themeColor:u,viewBox:v,name:_,onClick:P,...O}=e,w=t.useRef(null),y=H.useUnstyled(),h=y&&y.uSvgIcon;t.useImperativeHandle(l,()=>({element:w.current}));const b=t.useMemo(()=>n?n.name:c.icon,[n]),d=t.useMemo(()=>n?n.content:void 0,[n]),x=t.useMemo(()=>g||c.size,[g]),o=t.useMemo(()=>f||c.flip,[f]),C=t.useMemo(()=>v||c.viewBox,[v]),j=t.useMemo(()=>S.classNames(M.uSvgIcon.wrapper({c:h,iconNameProp:b,themeColor:u,flipH:o==="horizontal"||o==="both",flipV:o==="vertical"||o==="both",size:x}),r),[h,b,u,o,x,r]),B=t.useMemo(()=>e.width&&e.height?{width:e.width,height:e.height,...a}:e.width?{width:e.width,height:e.width,...a}:e.height?{width:e.height,height:e.height,...a}:{...a},[e.width,e.height,a]),T=t.useMemo(()=>d?{__html:d}:void 0,[d]);return t.createElement("span",{className:S.classNames(M.uSvgIcon.svg({c:h,themeColor:u,flipH:o==="horizontal"||o==="both",flipV:o==="vertical"||o==="both"}),j),style:B,ref:w,onClick:P,"aria-hidden":!0},t.createElement("svg",{id:p,className:N,style:I,"aria-hidden":!0,tabIndex:z,focusable:!1,xmlns:"http://www.w3.org/2000/svg",viewBox:n?n.viewBox:C,dangerouslySetInnerHTML:T,...O},n?void 0:s))});m.propTypes={style:i.object,classNames:i.string,children:i.any,icon:i.object,themeColor:i.oneOf(["inherit","primary","secondary","tertiary","info","success","error","warning","inverse"]),size:i.oneOf(["default","xsmall","small","medium","large","xlarge","xxlarge","xxxlarge"]),flip:i.oneOf(["default","horizontal","vertical","both"])};const c={size:"default",flip:"default",icon:"",viewBox:"0 0 24 24"};m.displayName="KendoSvgIcon";exports.SvgIcon=m;
|
package/icons/SvgIcon.mjs
CHANGED
|
@@ -17,12 +17,10 @@
|
|
|
17
17
|
* * `success`— Applies coloring based on success theme color.
|
|
18
18
|
* * `warning`— Applies coloring based on warning theme color.
|
|
19
19
|
* * `error`— Applies coloring based on error theme color.
|
|
20
|
-
* * `dark`— Applies coloring based on dark theme color.
|
|
21
|
-
* * `light`— Applies coloring based on light theme color.
|
|
22
20
|
* * `inverse`— Applies coloring based on inverse theme color.
|
|
23
21
|
*
|
|
24
22
|
* If the property is not set, the icon inherits the color from its parent.
|
|
25
23
|
*
|
|
26
24
|
* You can use the `style` prop to apply custom color related properties to the icon.
|
|
27
25
|
*/
|
|
28
|
-
export type IconThemeColor = 'inherit' | 'primary' | 'secondary' | 'tertiary' | 'info' | 'success' | 'warning' | 'error' | '
|
|
26
|
+
export type IconThemeColor = 'inherit' | 'primary' | 'secondary' | 'tertiary' | 'info' | 'success' | 'warning' | 'error' | 'inverse';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@progress/kendo-react-common",
|
|
3
|
-
"version": "14.5.0-develop.
|
|
3
|
+
"version": "14.5.0-develop.9",
|
|
4
4
|
"description": "React Common package delivers common utilities that can be used with the KendoReact UI components. KendoReact Common Utilities package",
|
|
5
5
|
"author": "Progress",
|
|
6
6
|
"license": "SEE LICENSE IN LICENSE.md",
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
"sideEffects": false,
|
|
27
27
|
"peerDependencies": {
|
|
28
28
|
"@progress/kendo-licensing": "^1.7.2",
|
|
29
|
-
"@progress/kendo-svg-icons": "^4.0.0",
|
|
29
|
+
"@progress/kendo-svg-icons": "^4.9.0 || ^5.0.0",
|
|
30
30
|
"react": "^18.0.0 || ^19.0.0",
|
|
31
31
|
"react-dom": "^18.0.0 || ^19.0.0"
|
|
32
32
|
},
|
|
@@ -58,5 +58,10 @@
|
|
|
58
58
|
},
|
|
59
59
|
"publishConfig": {
|
|
60
60
|
"access": "public"
|
|
61
|
+
},
|
|
62
|
+
"peerDependenciesMeta": {
|
|
63
|
+
"@progress/kendo-svg-icons": {
|
|
64
|
+
"optional": true
|
|
65
|
+
}
|
|
61
66
|
}
|
|
62
67
|
}
|
package/theme.js
CHANGED
|
@@ -5,4 +5,4 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e={sizeMap:{small:"sm",medium:"md",large:"lg"},roundedMap:{small:"sm",medium:"md",large:"lg",full:"full",none:"none"},orientationMap:{vertical:"vstack",horizontal:"hstack"}};exports.kendoThemeMaps=e;
|
|
8
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e={sizeMap:{xsmall:"xs",xs:"xs",small:"sm",medium:"md",large:"lg"},roundedMap:{small:"sm",medium:"md",large:"lg",full:"full",none:"none"},orientationMap:{vertical:"vstack",horizontal:"hstack"}};exports.kendoThemeMaps=e;
|
package/theme.mjs
CHANGED
|
@@ -5,8 +5,10 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
const
|
|
8
|
+
const l = {
|
|
9
9
|
sizeMap: {
|
|
10
|
+
xsmall: "xs",
|
|
11
|
+
xs: "xs",
|
|
10
12
|
small: "sm",
|
|
11
13
|
medium: "md",
|
|
12
14
|
large: "lg"
|
|
@@ -24,5 +26,5 @@ const e = {
|
|
|
24
26
|
}
|
|
25
27
|
};
|
|
26
28
|
export {
|
|
27
|
-
|
|
29
|
+
l as kendoThemeMaps
|
|
28
30
|
};
|
package/typography/Typography.js
CHANGED
|
@@ -6,4 +6,4 @@
|
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
8
|
"use client";
|
|
9
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const R=require("react"),t=require("prop-types"),a=require("./constants.js");function j(r){const c=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(r){for(const s in r)if(s!=="default"){const f=Object.getOwnPropertyDescriptor(r,s);Object.defineProperty(c,s,f.get?f:{enumerable:!0,get:()=>r[s]})}}return c.default=r,Object.freeze(c)}const l=j(R),n=r=>{const c=l.forwardRef((s,f)=>{const{id:y,style:h,className:m,fontSize:S,fontWeight:d,textAlign:T,textTransform:C,themeColor:E,margin:e,...O}=s,u=l.useRef(null),g=l.useRef(null);l.useImperativeHandle(u,()=>({element:g.current,props:s})),l.useImperativeHandle(f,()=>u.current);const _=()=>`k-${r==="p"?"paragraph":r}`,A=r,b=(i,p)=>{const o=typeof p=="string"?a.MARGIN_ENUM_VALUES[p]:p;return`${a.MARGIN_SIDES_CLASSES[i]}${o}`},N=()=>{if(e!==void 0){if(typeof e=="string")return[a.MARGIN_ENUM_CLASSES[e]];if(typeof e=="number"&&e>=0&&e<=24)return[`k-m-${e}`];if(typeof e=="object"){const i=[];return Object.keys(e).forEach(o=>{e[o]!==null&&e[o]!==void 0&&i.push(b(o,e[o]))}),i.join(" ")}}},M=()=>[_(),a.FONT_SIZE_CLASSES[S],a.FONT_WEIGHT_CLASSES[d],a.TEXT_ALIGN_CLASSES[T],a.TEXT_TRANSFORM_CLASSES[C],a.THEME_COLOR_CLASSES[E],N(),m].filter(o=>o!==void 0).join(" ");return l.createElement(A,{id:y,ref:g,className:M(),style:h,...O},s.children)});return c.propTypes={style:t.object,className:t.string,fontSize:t.oneOf(["xsmall","small","medium","large","xlarge"]),fontWeight:t.oneOf(["light","normal","bold"]),margin:t.oneOfType([t.number,t.object,t.oneOf(["xsmall","small","medium","large","xlarge","thin","hair"])]),textAlign:t.oneOf(["left","right","center","justify"]),textTransform:t.oneOf(["lowercase","uppercase","capitalize"]),themeColor:t.oneOf(["inherit","primary","secondary","tertiary","info","success","error","warning","
|
|
9
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const R=require("react"),t=require("prop-types"),a=require("./constants.js");function j(r){const c=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(r){for(const s in r)if(s!=="default"){const f=Object.getOwnPropertyDescriptor(r,s);Object.defineProperty(c,s,f.get?f:{enumerable:!0,get:()=>r[s]})}}return c.default=r,Object.freeze(c)}const l=j(R),n=r=>{const c=l.forwardRef((s,f)=>{const{id:y,style:h,className:m,fontSize:S,fontWeight:d,textAlign:T,textTransform:C,themeColor:E,margin:e,...O}=s,u=l.useRef(null),g=l.useRef(null);l.useImperativeHandle(u,()=>({element:g.current,props:s})),l.useImperativeHandle(f,()=>u.current);const _=()=>`k-${r==="p"?"paragraph":r}`,A=r,b=(i,p)=>{const o=typeof p=="string"?a.MARGIN_ENUM_VALUES[p]:p;return`${a.MARGIN_SIDES_CLASSES[i]}${o}`},N=()=>{if(e!==void 0){if(typeof e=="string")return[a.MARGIN_ENUM_CLASSES[e]];if(typeof e=="number"&&e>=0&&e<=24)return[`k-m-${e}`];if(typeof e=="object"){const i=[];return Object.keys(e).forEach(o=>{e[o]!==null&&e[o]!==void 0&&i.push(b(o,e[o]))}),i.join(" ")}}},M=()=>[_(),a.FONT_SIZE_CLASSES[S],a.FONT_WEIGHT_CLASSES[d],a.TEXT_ALIGN_CLASSES[T],a.TEXT_TRANSFORM_CLASSES[C],a.THEME_COLOR_CLASSES[E],N(),m].filter(o=>o!==void 0).join(" ");return l.createElement(A,{id:y,ref:g,className:M(),style:h,...O},s.children)});return c.propTypes={style:t.object,className:t.string,fontSize:t.oneOf(["xsmall","small","medium","large","xlarge"]),fontWeight:t.oneOf(["light","normal","bold"]),margin:t.oneOfType([t.number,t.object,t.oneOf(["xsmall","small","medium","large","xlarge","thin","hair"])]),textAlign:t.oneOf(["left","right","center","justify"]),textTransform:t.oneOf(["lowercase","uppercase","capitalize"]),themeColor:t.oneOf(["inherit","primary","secondary","tertiary","info","success","error","warning","inverse"])},c.displayName=`KendoReactTypography${r.toUpperCase()}`,c},L=n("h1"),I=n("h2"),x=n("h3"),v=n("h4"),G=n("h5"),P=n("h6"),$=n("p"),w=n("code"),z=n("pre"),H={h1:L,h2:I,h3:x,h4:v,h5:G,h6:P,p:$,code:w,pre:z};exports.Typography=H;
|
|
@@ -11,7 +11,7 @@ import t from "prop-types";
|
|
|
11
11
|
import { FONT_SIZE_CLASSES as L, FONT_WEIGHT_CLASSES as M, TEXT_ALIGN_CLASSES as x, TEXT_TRANSFORM_CLASSES as I, THEME_COLOR_CLASSES as b, MARGIN_ENUM_CLASSES as j, MARGIN_SIDES_CLASSES as v, MARGIN_ENUM_VALUES as G } from "./constants.mjs";
|
|
12
12
|
const r = (c) => {
|
|
13
13
|
const i = n.forwardRef((l, h) => {
|
|
14
|
-
const { id: m, style: g, className: y, fontSize: S, fontWeight: u, textAlign:
|
|
14
|
+
const { id: m, style: g, className: y, fontSize: S, fontWeight: u, textAlign: C, textTransform: E, themeColor: d, margin: e, ...T } = l, p = n.useRef(null), f = n.useRef(null);
|
|
15
15
|
n.useImperativeHandle(p, () => ({
|
|
16
16
|
element: f.current,
|
|
17
17
|
props: l
|
|
@@ -36,9 +36,9 @@ const r = (c) => {
|
|
|
36
36
|
A(),
|
|
37
37
|
L[S],
|
|
38
38
|
M[u],
|
|
39
|
-
x[
|
|
40
|
-
I[
|
|
41
|
-
b[
|
|
39
|
+
x[C],
|
|
40
|
+
I[E],
|
|
41
|
+
b[d],
|
|
42
42
|
O(),
|
|
43
43
|
y
|
|
44
44
|
].filter((s) => s !== void 0).join(" ");
|
|
@@ -65,12 +65,10 @@ const r = (c) => {
|
|
|
65
65
|
"success",
|
|
66
66
|
"error",
|
|
67
67
|
"warning",
|
|
68
|
-
"dark",
|
|
69
|
-
"light",
|
|
70
68
|
"inverse"
|
|
71
69
|
])
|
|
72
70
|
}, i.displayName = `KendoReactTypography${c.toUpperCase()}`, i;
|
|
73
|
-
}, $ = r("h1"), H = r("h2"), U = r("h3"), w = r("h4"), z = r("h5"), F = r("h6"), W = r("p"), P = r("code"), X = r("pre"),
|
|
71
|
+
}, $ = r("h1"), H = r("h2"), U = r("h3"), w = r("h4"), z = r("h5"), F = r("h6"), W = r("p"), P = r("code"), X = r("pre"), V = {
|
|
74
72
|
h1: $,
|
|
75
73
|
h2: H,
|
|
76
74
|
h3: U,
|
|
@@ -82,5 +80,5 @@ const r = (c) => {
|
|
|
82
80
|
pre: X
|
|
83
81
|
};
|
|
84
82
|
export {
|
|
85
|
-
|
|
83
|
+
V as Typography
|
|
86
84
|
};
|
|
@@ -112,14 +112,12 @@ export interface TypographyProps extends KendoReactComponentBaseProps {
|
|
|
112
112
|
* * `success`— Applies coloring based on success theme color.
|
|
113
113
|
* * `warning`— Applies coloring based on warning theme color.
|
|
114
114
|
* * `error`— Applies coloring based on error theme color.
|
|
115
|
-
* * `dark`— Applies coloring based on dark theme color.
|
|
116
|
-
* * `light`— Applies coloring based on light theme color.
|
|
117
115
|
* * `inverse`— Applies coloring based on inverse theme color.
|
|
118
116
|
*
|
|
119
117
|
* You can use the `style` property to apply custom color related properties to the element.
|
|
120
118
|
*
|
|
121
119
|
*/
|
|
122
|
-
themeColor?: 'inherit' | 'primary' | 'secondary' | 'tertiary' | 'info' | 'success' | 'warning' | 'error' | '
|
|
120
|
+
themeColor?: 'inherit' | 'primary' | 'secondary' | 'tertiary' | 'info' | 'success' | 'warning' | 'error' | 'inverse';
|
|
123
121
|
/**
|
|
124
122
|
* Sets a custom property to the element.
|
|
125
123
|
*/
|
package/unstyled/buttons.d.ts
CHANGED
package/unstyled/buttons.js
CHANGED
|
@@ -5,4 +5,4 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("./interfaces/common.js"),e=require("./json-classes.js"),d={wrapper:{main:e.buttonPrefix,size:{small:`${e.buttonPrefix}-${e.sizeMap.small}`,medium:`${e.buttonPrefix}-${e.sizeMap.medium}`,large:`${e.buttonPrefix}-${e.sizeMap.large}`},fillMode:{solid:`${e.buttonPrefix}-${e.fillModeMap.solid}`,outline:`${e.buttonPrefix}-${e.fillModeMap.outline}`,flat:`${e.buttonPrefix}-${e.fillModeMap.flat}`,link:`${e.buttonPrefix}-${e.fillModeMap.link}`,clear:`${e.buttonPrefix}-${e.fillModeMap.clear}`},themeColor:{base:`${e.buttonPrefix}-${e.themeColorMap.base}`,primary:`${e.buttonPrefix}-${e.themeColorMap.primary}`,secondary:`${e.buttonPrefix}-${e.themeColorMap.secondary}`,tertiary:`${e.buttonPrefix}-${e.themeColorMap.tertiary}`,info:`${e.buttonPrefix}-${e.themeColorMap.info}`,success:`${e.buttonPrefix}-${e.themeColorMap.success}`,warning:`${e.buttonPrefix}-${e.themeColorMap.warning}`,error:`${e.buttonPrefix}-${e.themeColorMap.error}`,dark:`${e.buttonPrefix}-${e.themeColorMap.dark}`,light:`${e.buttonPrefix}-${e.themeColorMap.light}`,inverse:`${e.buttonPrefix}-${e.themeColorMap.inverse}`},rounded:{small:`${e.base.prefix}-${e.base.rounded}-${e.roundedMap.small}`,medium:`${e.base.prefix}-${e.base.rounded}-${e.roundedMap.medium}`,large:`${e.base.prefix}-${e.base.rounded}-${e.roundedMap.large}`},iconButton:`${e.base.prefix}-${e.elements.icon}-${e.elements.button}`,disabled:`${e.base.prefix}-${e.states.disabled}`,selected:`${e.base.prefix}-${e.states.selected}`,isRtl:`${e.base.prefix}-${e.base.rtl}`},text:`${e.buttonPrefix}-${e.elements.text}`,icon:`${e.buttonPrefix}-${e.elements.icon}`},x={wrapper:o=>{const{isRtl:r,selected:n,disabled:s,size:t,fillMode:u,rounded:a,themeColor:$,iconButton:f,c:m=d}=o,i=m.wrapper,p=$&&i.themeColor?i.themeColor[$]:void 0;return{[i.main]:!0,[i.size[t]]:t&&i.size[t],[`${e.buttonPrefix}-${t}`]:t&&!i.size[t],[i.fillMode[u]]:u&&i.fillMode[u],[p]:p,[i.rounded[a]]:a&&i.rounded[a],[`${e.base.prefix}-${e.base.rounded}-${a}`]:a&&!i.rounded[a],[i.iconButton]:f,[i.disabled]:s,[i.selected]:n,[i.isRtl]:r}},text:o=>{const{c:r=d}=o;return{[r.text]:!0}},icon:o=>{const{c:r=d}=o;return{[r.icon]:!0}}},b={wrapper:{main:`${e.buttonPrefix}-${e.containers.group}`,stretched:`${e.buttonPrefix}-${e.containers.group}-${e.states.stretched}`,disabled:`${e.base.prefix}-${e.states.disabled}`},position:{start:`${e.base.prefix}-${e.containers.group}-${e.directionMap.start}`,end:`${e.base.prefix}-${e.containers.group}-${e.directionMap.end}`}},M={wrapper:o=>{const{stretched:r,disabled:n,c:s=b}=o,t=s.wrapper;return{[t.main]:!0,[t.stretched]:r,[t.disabled]:n}},position:o=>{const{start:r,end:n,c:s=b}=o,t=s.position;return{[t.start]:r,[t.end]:n}}},l={wrapper:{main:`${e.ddbPrefix}-${e.elements.button}`,focus:`${e.base.prefix}-${e.states.focus}`,disabled:`${e.base.prefix}-${e.states.disabled}`},ul:{group:`${e.ddbPrefix}-${e.containers.group}`,size:{small:`${e.ddbPrefix}-${e.containers.group}-${e.sizeMap.small}`,medium:`${e.ddbPrefix}-${e.containers.group}-${e.sizeMap.medium}`,large:`${e.ddbPrefix}-${e.containers.group}-${e.sizeMap.large}`}},li:{item:`${e.base.prefix}-${e.containers.item}`,focus:`${e.base.prefix}-${e.states.focus}`},item:`${e.ddbPrefix}-${e.containers.item}`,link:{main:`${e.base.prefix}-${e.elements.link}`,link:`${e.ddbPrefix}-${e.elements.link}`,selected:`${e.base.prefix}-${e.states.selected}`,disabled:`${e.base.prefix}-${e.states.disabled}`},popup:`${e.ddbPrefix}-${e.containers.popup}`},P={wrapper:o=>{const{focused:r,disabled:n,c:s=l}=o,t=s.wrapper;return{[t.main]:!0,[t.focus]:r,[t.disabled]:n}},ul:o=>{const{size:r,c:n=l}=o,s=n.ul;return{[s.group]:!0,[s.size[r]]:s.size[r],[`${e.ddbPrefix}-${e.containers.group}-${r}`]:r&&!s.size[r]}},li:o=>{const{focused:r,c:n=l}=o,s=n.li;return{[s.item]:!0,[s.focus]:r}},item:c.getClassByName(l,"item"),link:o=>{const{selected:r,disabled:n,c:s=l}=o,t=s.link;return{[t.main]:!0,[t.link]:!0,[t.selected]:r,[t.disabled]:n}},popup:c.getClassByName(l,"popup")};exports.uButton=x;exports.uButtonGroup=M;exports.uDropDownButton=P;
|
|
8
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("./interfaces/common.js"),e=require("./json-classes.js"),d={wrapper:{main:e.buttonPrefix,size:{xs:`${e.buttonPrefix}-${e.sizeMap.xsmall}`,small:`${e.buttonPrefix}-${e.sizeMap.small}`,medium:`${e.buttonPrefix}-${e.sizeMap.medium}`,large:`${e.buttonPrefix}-${e.sizeMap.large}`},fillMode:{solid:`${e.buttonPrefix}-${e.fillModeMap.solid}`,outline:`${e.buttonPrefix}-${e.fillModeMap.outline}`,flat:`${e.buttonPrefix}-${e.fillModeMap.flat}`,link:`${e.buttonPrefix}-${e.fillModeMap.link}`,clear:`${e.buttonPrefix}-${e.fillModeMap.clear}`},themeColor:{base:`${e.buttonPrefix}-${e.themeColorMap.base}`,primary:`${e.buttonPrefix}-${e.themeColorMap.primary}`,secondary:`${e.buttonPrefix}-${e.themeColorMap.secondary}`,tertiary:`${e.buttonPrefix}-${e.themeColorMap.tertiary}`,info:`${e.buttonPrefix}-${e.themeColorMap.info}`,success:`${e.buttonPrefix}-${e.themeColorMap.success}`,warning:`${e.buttonPrefix}-${e.themeColorMap.warning}`,error:`${e.buttonPrefix}-${e.themeColorMap.error}`,dark:`${e.buttonPrefix}-${e.themeColorMap.dark}`,light:`${e.buttonPrefix}-${e.themeColorMap.light}`,inverse:`${e.buttonPrefix}-${e.themeColorMap.inverse}`},rounded:{small:`${e.base.prefix}-${e.base.rounded}-${e.roundedMap.small}`,medium:`${e.base.prefix}-${e.base.rounded}-${e.roundedMap.medium}`,large:`${e.base.prefix}-${e.base.rounded}-${e.roundedMap.large}`},iconButton:`${e.base.prefix}-${e.elements.icon}-${e.elements.button}`,disabled:`${e.base.prefix}-${e.states.disabled}`,selected:`${e.base.prefix}-${e.states.selected}`,isRtl:`${e.base.prefix}-${e.base.rtl}`},text:`${e.buttonPrefix}-${e.elements.text}`,icon:`${e.buttonPrefix}-${e.elements.icon}`},x={wrapper:o=>{const{isRtl:r,selected:n,disabled:s,size:t,fillMode:u,rounded:a,themeColor:$,iconButton:f,c:m=d}=o,i=m.wrapper,p=$&&i.themeColor?i.themeColor[$]:void 0;return{[i.main]:!0,[i.size[t]]:t&&i.size[t],[`${e.buttonPrefix}-${t}`]:t&&!i.size[t],[i.fillMode[u]]:u&&i.fillMode[u],[p]:p,[i.rounded[a]]:a&&i.rounded[a],[`${e.base.prefix}-${e.base.rounded}-${a}`]:a&&!i.rounded[a],[i.iconButton]:f,[i.disabled]:s,[i.selected]:n,[i.isRtl]:r}},text:o=>{const{c:r=d}=o;return{[r.text]:!0}},icon:o=>{const{c:r=d}=o;return{[r.icon]:!0}}},b={wrapper:{main:`${e.buttonPrefix}-${e.containers.group}`,stretched:`${e.buttonPrefix}-${e.containers.group}-${e.states.stretched}`,disabled:`${e.base.prefix}-${e.states.disabled}`},position:{start:`${e.base.prefix}-${e.containers.group}-${e.directionMap.start}`,end:`${e.base.prefix}-${e.containers.group}-${e.directionMap.end}`}},M={wrapper:o=>{const{stretched:r,disabled:n,c:s=b}=o,t=s.wrapper;return{[t.main]:!0,[t.stretched]:r,[t.disabled]:n}},position:o=>{const{start:r,end:n,c:s=b}=o,t=s.position;return{[t.start]:r,[t.end]:n}}},l={wrapper:{main:`${e.ddbPrefix}-${e.elements.button}`,focus:`${e.base.prefix}-${e.states.focus}`,disabled:`${e.base.prefix}-${e.states.disabled}`},ul:{group:`${e.ddbPrefix}-${e.containers.group}`,size:{small:`${e.ddbPrefix}-${e.containers.group}-${e.sizeMap.small}`,medium:`${e.ddbPrefix}-${e.containers.group}-${e.sizeMap.medium}`,large:`${e.ddbPrefix}-${e.containers.group}-${e.sizeMap.large}`}},li:{item:`${e.base.prefix}-${e.containers.item}`,focus:`${e.base.prefix}-${e.states.focus}`},item:`${e.ddbPrefix}-${e.containers.item}`,link:{main:`${e.base.prefix}-${e.elements.link}`,link:`${e.ddbPrefix}-${e.elements.link}`,selected:`${e.base.prefix}-${e.states.selected}`,disabled:`${e.base.prefix}-${e.states.disabled}`},popup:`${e.ddbPrefix}-${e.containers.popup}`},P={wrapper:o=>{const{focused:r,disabled:n,c:s=l}=o,t=s.wrapper;return{[t.main]:!0,[t.focus]:r,[t.disabled]:n}},ul:o=>{const{size:r,c:n=l}=o,s=n.ul;return{[s.group]:!0,[s.size[r]]:s.size[r],[`${e.ddbPrefix}-${e.containers.group}-${r}`]:r&&!s.size[r]}},li:o=>{const{focused:r,c:n=l}=o,s=n.li;return{[s.item]:!0,[s.focus]:r}},item:c.getClassByName(l,"item"),link:o=>{const{selected:r,disabled:n,c:s=l}=o,t=s.link;return{[t.main]:!0,[t.link]:!0,[t.selected]:r,[t.disabled]:n}},popup:c.getClassByName(l,"popup")};exports.uButton=x;exports.uButtonGroup=M;exports.uDropDownButton=P;
|
package/unstyled/buttons.mjs
CHANGED
|
@@ -6,21 +6,22 @@
|
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
8
|
import { getClassByName as z } from "./interfaces/common.mjs";
|
|
9
|
-
import { buttonPrefix as e, elements as u, base as r, states as
|
|
9
|
+
import { buttonPrefix as e, elements as u, base as r, states as p, roundedMap as g, themeColorMap as d, fillModeMap as x, sizeMap as c, containers as l, directionMap as C, ddbPrefix as a } from "./json-classes.mjs";
|
|
10
10
|
const w = {
|
|
11
11
|
wrapper: {
|
|
12
12
|
main: e,
|
|
13
13
|
size: {
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
14
|
+
xs: `${e}-${c.xsmall}`,
|
|
15
|
+
small: `${e}-${c.small}`,
|
|
16
|
+
medium: `${e}-${c.medium}`,
|
|
17
|
+
large: `${e}-${c.large}`
|
|
17
18
|
},
|
|
18
19
|
fillMode: {
|
|
19
|
-
solid: `${e}-${
|
|
20
|
-
outline: `${e}-${
|
|
21
|
-
flat: `${e}-${
|
|
22
|
-
link: `${e}-${
|
|
23
|
-
clear: `${e}-${
|
|
20
|
+
solid: `${e}-${x.solid}`,
|
|
21
|
+
outline: `${e}-${x.outline}`,
|
|
22
|
+
flat: `${e}-${x.flat}`,
|
|
23
|
+
link: `${e}-${x.link}`,
|
|
24
|
+
clear: `${e}-${x.clear}`
|
|
24
25
|
},
|
|
25
26
|
themeColor: {
|
|
26
27
|
base: `${e}-${d.base}`,
|
|
@@ -41,23 +42,23 @@ const w = {
|
|
|
41
42
|
large: `${r.prefix}-${r.rounded}-${g.large}`
|
|
42
43
|
},
|
|
43
44
|
iconButton: `${r.prefix}-${u.icon}-${u.button}`,
|
|
44
|
-
disabled: `${r.prefix}-${
|
|
45
|
-
selected: `${r.prefix}-${
|
|
45
|
+
disabled: `${r.prefix}-${p.disabled}`,
|
|
46
|
+
selected: `${r.prefix}-${p.selected}`,
|
|
46
47
|
isRtl: `${r.prefix}-${r.rtl}`
|
|
47
48
|
},
|
|
48
49
|
text: `${e}-${u.text}`,
|
|
49
50
|
icon: `${e}-${u.icon}`
|
|
50
51
|
}, R = {
|
|
51
52
|
wrapper: (o) => {
|
|
52
|
-
const { isRtl: i, selected: n, disabled: s, size: t, fillMode:
|
|
53
|
+
const { isRtl: i, selected: n, disabled: s, size: t, fillMode: b, rounded: m, themeColor: h, iconButton: B, c: y = w } = o, $ = y.wrapper, k = h && $.themeColor ? $.themeColor[h] : void 0;
|
|
53
54
|
return {
|
|
54
55
|
[$.main]: !0,
|
|
55
56
|
[$.size[t]]: t && $.size[t],
|
|
56
57
|
[`${e}-${t}`]: t && !$.size[t],
|
|
57
|
-
[$.fillMode[
|
|
58
|
+
[$.fillMode[b]]: b && $.fillMode[b],
|
|
58
59
|
[k]: k,
|
|
59
|
-
[$.rounded[
|
|
60
|
-
[`${r.prefix}-${r.rounded}-${
|
|
60
|
+
[$.rounded[m]]: m && $.rounded[m],
|
|
61
|
+
[`${r.prefix}-${r.rounded}-${m}`]: m && !$.rounded[m],
|
|
61
62
|
[$.iconButton]: B,
|
|
62
63
|
[$.disabled]: s,
|
|
63
64
|
[$.selected]: n,
|
|
@@ -79,8 +80,8 @@ const w = {
|
|
|
79
80
|
}, M = {
|
|
80
81
|
wrapper: {
|
|
81
82
|
main: `${e}-${l.group}`,
|
|
82
|
-
stretched: `${e}-${l.group}-${
|
|
83
|
-
disabled: `${r.prefix}-${
|
|
83
|
+
stretched: `${e}-${l.group}-${p.stretched}`,
|
|
84
|
+
disabled: `${r.prefix}-${p.disabled}`
|
|
84
85
|
},
|
|
85
86
|
position: {
|
|
86
87
|
start: `${r.prefix}-${l.group}-${C.start}`,
|
|
@@ -102,35 +103,35 @@ const w = {
|
|
|
102
103
|
[t.end]: n
|
|
103
104
|
};
|
|
104
105
|
}
|
|
105
|
-
},
|
|
106
|
+
}, f = {
|
|
106
107
|
wrapper: {
|
|
107
|
-
main: `${
|
|
108
|
-
focus: `${r.prefix}-${
|
|
109
|
-
disabled: `${r.prefix}-${
|
|
108
|
+
main: `${a}-${u.button}`,
|
|
109
|
+
focus: `${r.prefix}-${p.focus}`,
|
|
110
|
+
disabled: `${r.prefix}-${p.disabled}`
|
|
110
111
|
},
|
|
111
112
|
ul: {
|
|
112
|
-
group: `${
|
|
113
|
+
group: `${a}-${l.group}`,
|
|
113
114
|
size: {
|
|
114
|
-
small: `${
|
|
115
|
-
medium: `${
|
|
116
|
-
large: `${
|
|
115
|
+
small: `${a}-${l.group}-${c.small}`,
|
|
116
|
+
medium: `${a}-${l.group}-${c.medium}`,
|
|
117
|
+
large: `${a}-${l.group}-${c.large}`
|
|
117
118
|
}
|
|
118
119
|
},
|
|
119
120
|
li: {
|
|
120
121
|
item: `${r.prefix}-${l.item}`,
|
|
121
|
-
focus: `${r.prefix}-${
|
|
122
|
+
focus: `${r.prefix}-${p.focus}`
|
|
122
123
|
},
|
|
123
|
-
item: `${
|
|
124
|
+
item: `${a}-${l.item}`,
|
|
124
125
|
link: {
|
|
125
126
|
main: `${r.prefix}-${u.link}`,
|
|
126
|
-
link: `${
|
|
127
|
-
selected: `${r.prefix}-${
|
|
128
|
-
disabled: `${r.prefix}-${
|
|
127
|
+
link: `${a}-${u.link}`,
|
|
128
|
+
selected: `${r.prefix}-${p.selected}`,
|
|
129
|
+
disabled: `${r.prefix}-${p.disabled}`
|
|
129
130
|
},
|
|
130
|
-
popup: `${
|
|
131
|
+
popup: `${a}-${l.popup}`
|
|
131
132
|
}, P = {
|
|
132
133
|
wrapper: (o) => {
|
|
133
|
-
const { focused: i, disabled: n, c: s =
|
|
134
|
+
const { focused: i, disabled: n, c: s = f } = o, t = s.wrapper;
|
|
134
135
|
return {
|
|
135
136
|
[t.main]: !0,
|
|
136
137
|
[t.focus]: i,
|
|
@@ -138,23 +139,23 @@ const w = {
|
|
|
138
139
|
};
|
|
139
140
|
},
|
|
140
141
|
ul: (o) => {
|
|
141
|
-
const { size: i, c: n =
|
|
142
|
+
const { size: i, c: n = f } = o, s = n.ul;
|
|
142
143
|
return {
|
|
143
144
|
[s.group]: !0,
|
|
144
145
|
[s.size[i]]: s.size[i],
|
|
145
|
-
[`${
|
|
146
|
+
[`${a}-${l.group}-${i}`]: i && !s.size[i]
|
|
146
147
|
};
|
|
147
148
|
},
|
|
148
149
|
li: (o) => {
|
|
149
|
-
const { focused: i, c: n =
|
|
150
|
+
const { focused: i, c: n = f } = o, s = n.li;
|
|
150
151
|
return {
|
|
151
152
|
[s.item]: !0,
|
|
152
153
|
[s.focus]: i
|
|
153
154
|
};
|
|
154
155
|
},
|
|
155
|
-
item: z(
|
|
156
|
+
item: z(f, "item"),
|
|
156
157
|
link: (o) => {
|
|
157
|
-
const { selected: i, disabled: n, c: s =
|
|
158
|
+
const { selected: i, disabled: n, c: s = f } = o, t = s.link;
|
|
158
159
|
return {
|
|
159
160
|
[t.main]: !0,
|
|
160
161
|
[t.link]: !0,
|
|
@@ -162,7 +163,7 @@ const w = {
|
|
|
162
163
|
[t.disabled]: n
|
|
163
164
|
};
|
|
164
165
|
},
|
|
165
|
-
popup: z(
|
|
166
|
+
popup: z(f, "popup")
|
|
166
167
|
};
|
|
167
168
|
export {
|
|
168
169
|
R as uButton,
|
package/unstyled/icons.d.ts
CHANGED
|
@@ -24,10 +24,8 @@ export interface ThemeColorClasses {
|
|
|
24
24
|
warning?: string;
|
|
25
25
|
/** Text color indicating errors */
|
|
26
26
|
error?: string;
|
|
27
|
-
/** Text color for
|
|
28
|
-
|
|
29
|
-
/** Text color for light theme */
|
|
30
|
-
light?: string;
|
|
27
|
+
/** Text color for inverse theme */
|
|
28
|
+
inverse?: string;
|
|
31
29
|
}
|
|
32
30
|
/** Size options */
|
|
33
31
|
export interface SizeClasses {
|
package/unstyled/icons.js
CHANGED
|
@@ -5,4 +5,4 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./json-classes.js"),l={wrapper:{main:`${e.base.prefix}-${e.icon.prefix}`,svgPrefix:`${e.base.prefix}-${e.icon.svg}-${e.icon.prefix}`,namePrefix:`${e.base.prefix}-${e.icon.svg}-${e.icon.i}-`,flipH:`${e.base.prefix}-${e.icon.flipH}`,flipV:`${e.base.prefix}-${e.icon.flipV}`,themeColor:{inherit:`${e.base.prefix}-${e.icon.color}-${e.themeColorMap.inherit}`,primary:`${e.base.prefix}-${e.icon.color}-${e.themeColorMap.primary}`,secondary:`${e.base.prefix}-${e.icon.color}-${e.themeColorMap.secondary}`,tertiary:`${e.base.prefix}-${e.icon.color}-${e.themeColorMap.tertiary}`,info:`${e.base.prefix}-${e.icon.color}-${e.themeColorMap.info}`,success:`${e.base.prefix}-${e.icon.color}-${e.themeColorMap.success}`,warning:`${e.base.prefix}-${e.icon.color}-${e.themeColorMap.warning}`,error:`${e.base.prefix}-${e.icon.color}-${e.themeColorMap.error}`,
|
|
8
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./json-classes.js"),l={wrapper:{main:`${e.base.prefix}-${e.icon.prefix}`,svgPrefix:`${e.base.prefix}-${e.icon.svg}-${e.icon.prefix}`,namePrefix:`${e.base.prefix}-${e.icon.svg}-${e.icon.i}-`,flipH:`${e.base.prefix}-${e.icon.flipH}`,flipV:`${e.base.prefix}-${e.icon.flipV}`,themeColor:{inherit:`${e.base.prefix}-${e.icon.color}-${e.themeColorMap.inherit}`,primary:`${e.base.prefix}-${e.icon.color}-${e.themeColorMap.primary}`,secondary:`${e.base.prefix}-${e.icon.color}-${e.themeColorMap.secondary}`,tertiary:`${e.base.prefix}-${e.icon.color}-${e.themeColorMap.tertiary}`,info:`${e.base.prefix}-${e.icon.color}-${e.themeColorMap.info}`,success:`${e.base.prefix}-${e.icon.color}-${e.themeColorMap.success}`,warning:`${e.base.prefix}-${e.icon.color}-${e.themeColorMap.warning}`,error:`${e.base.prefix}-${e.icon.color}-${e.themeColorMap.error}`,inverse:`${e.base.prefix}-${e.icon.color}-${e.themeColorMap.inverse}`},size:{default:"",xsmall:`${e.base.prefix}-${e.icon.prefix}-${e.sizeMap.xsmall}`,small:`${e.base.prefix}-${e.icon.prefix}-${e.sizeMap.small}`,medium:`${e.base.prefix}-${e.icon.prefix}-${e.sizeMap.medium}`,large:`${e.base.prefix}-${e.icon.prefix}-${e.sizeMap.large}`,xlarge:`${e.base.prefix}-${e.icon.prefix}-${e.sizeMap.xlarge}`,xxlarge:`${e.base.prefix}-${e.icon.prefix}-${e.sizeMap.xxlarge}`,xxxlarge:`${e.base.prefix}-${e.icon.prefix}-${e.sizeMap.xxxlarge}`}},svg:{main:"",flipH:"",flipV:""}},c={wrapper:p=>{const{iconNameProp:o,themeColor:a,flipH:s,flipV:r,size:$,c:n=l}=p,i=n.wrapper||{};return{[i.main||""]:!0,[i.svgPrefix||""]:!0,[`${i.namePrefix||""}${o}`]:o,[i.themeColor[a]||""]:a,[i.flipH||""]:s,[i.flipV||""]:r,[i.size[$]||""]:i.size[$]}},svg:p=>{const{flipH:o,flipV:a,c:s=l}=p,r=s.svg;return{[r.main||""]:!0,[r.flipH||""]:o,[r.flipV||""]:a}}};exports.uSvgIcon=c;
|
package/unstyled/icons.mjs
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
8
|
import { base as e, icon as r, sizeMap as p, themeColorMap as i } from "./json-classes.mjs";
|
|
9
|
-
const
|
|
9
|
+
const n = {
|
|
10
10
|
wrapper: {
|
|
11
11
|
main: `${e.prefix}-${r.prefix}`,
|
|
12
12
|
svgPrefix: `${e.prefix}-${r.svg}-${r.prefix}`,
|
|
@@ -22,8 +22,7 @@ const c = {
|
|
|
22
22
|
success: `${e.prefix}-${r.color}-${i.success}`,
|
|
23
23
|
warning: `${e.prefix}-${r.color}-${i.warning}`,
|
|
24
24
|
error: `${e.prefix}-${r.color}-${i.error}`,
|
|
25
|
-
|
|
26
|
-
light: `${e.prefix}-${r.color}-${i.light}`
|
|
25
|
+
inverse: `${e.prefix}-${r.color}-${i.inverse}`
|
|
27
26
|
},
|
|
28
27
|
size: {
|
|
29
28
|
default: "",
|
|
@@ -42,24 +41,24 @@ const c = {
|
|
|
42
41
|
flipV: ""
|
|
43
42
|
}
|
|
44
43
|
}, m = {
|
|
45
|
-
wrapper: (
|
|
46
|
-
const { iconNameProp: x, themeColor:
|
|
44
|
+
wrapper: (l) => {
|
|
45
|
+
const { iconNameProp: x, themeColor: o, flipH: s, flipV: f, size: a, c = n } = l, $ = c.wrapper || {};
|
|
47
46
|
return {
|
|
48
47
|
[$.main || ""]: !0,
|
|
49
48
|
[$.svgPrefix || ""]: !0,
|
|
50
49
|
[`${$.namePrefix || ""}${x}`]: x,
|
|
51
|
-
[$.themeColor[
|
|
52
|
-
[$.flipH || ""]:
|
|
50
|
+
[$.themeColor[o] || ""]: o,
|
|
51
|
+
[$.flipH || ""]: s,
|
|
53
52
|
[$.flipV || ""]: f,
|
|
54
|
-
[$.size[
|
|
53
|
+
[$.size[a] || ""]: $.size[a]
|
|
55
54
|
};
|
|
56
55
|
},
|
|
57
|
-
svg: (
|
|
58
|
-
const { flipH: x, flipV:
|
|
56
|
+
svg: (l) => {
|
|
57
|
+
const { flipH: x, flipV: o, c: s = n } = l, f = s.svg;
|
|
59
58
|
return {
|
|
60
59
|
[f.main || ""]: !0,
|
|
61
60
|
[f.flipH || ""]: x,
|
|
62
|
-
[f.flipV || ""]:
|
|
61
|
+
[f.flipV || ""]: o
|
|
63
62
|
};
|
|
64
63
|
}
|
|
65
64
|
};
|
package/unstyled/json-classes.js
CHANGED
|
@@ -5,4 +5,4 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e={prefix:"k",important:"!",rtl:"rtl",rounded:"rounded",value:"value",state:"state",filter:"filter",virtual:"virtual",infinite:"infinite",clear:"clear",reset:"reset",data:"data",nodata:"nodata",scroller:"scroller"},n={center:"center",hbox:"hbox",vstack:"vstack",hstack:"hstack",overflow:"overflow"},t={actionsheet:"actionsheet",calendar:"calendar",buttongroup:"buttongroup",dateinput:"dateinput",datetime:"datetime",datetimepicker:"datetimepicker",dropdownlist:"dropdownlist",combobox:"combobox",maskedtextbox:"maskedtextbox",menu:"menu",searchbox:"searchbox",timepicker:"timepicker"},l={xsmall:"xs",small:"sm",medium:"md",large:"lg",xlarge:"xl",xxlarge:"xxl",xxxlarge:"xxxl"},s={solid:"solid",outline:"outline",flat:"flat",link:"link",clear:"clear"},c={base:"base",primary:"primary",secondary:"secondary",tertiary:"tertiary",info:"info",success:"success",warning:"warning",error:"error",
|
|
8
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e={prefix:"k",important:"!",rtl:"rtl",rounded:"rounded",value:"value",state:"state",filter:"filter",virtual:"virtual",infinite:"infinite",clear:"clear",reset:"reset",data:"data",nodata:"nodata",scroller:"scroller"},n={center:"center",hbox:"hbox",vstack:"vstack",hstack:"hstack",overflow:"overflow"},t={actionsheet:"actionsheet",calendar:"calendar",buttongroup:"buttongroup",dateinput:"dateinput",datetime:"datetime",datetimepicker:"datetimepicker",dropdownlist:"dropdownlist",combobox:"combobox",maskedtextbox:"maskedtextbox",menu:"menu",searchbox:"searchbox",timepicker:"timepicker"},l={xsmall:"xs",small:"sm",medium:"md",large:"lg",xlarge:"xl",xxlarge:"xxl",xxxlarge:"xxxl"},s={solid:"solid",outline:"outline",flat:"flat",link:"link",clear:"clear"},c={base:"base",primary:"primary",secondary:"secondary",tertiary:"tertiary",info:"info",success:"success",warning:"warning",error:"error",inherit:"inherit",inverse:"inverse"},d={small:"sm",medium:"md",large:"lg",full:"full",none:"none"},p={vertical:"vertical",horizontal:"horizontal"},f={height:"height",width:"width"},m={default:"cursor-default"},u={up:"up",down:"down",left:"left",right:"right",start:"start",mid:"mid",end:"end"},r={actions:"actions",container:"container",content:"content",group:"group",row:"row",nav:"nav",wrap:"wrap",wrapper:"wrapper",list:"list",placeholder:"placeholder",popup:"popup",item:"item",part:"part",picker:"picker",separator:"separator",spacer:"spacer",tab:"tab",titlebar:"titlebar",optionLabel:"optionlabel",view:"view"},o={table:"table",text:"text",button:"button",tbody:"tbody",thead:"thead",tr:"tr",th:"th",td:"td",header:"header",footer:"footer",icon:"icon",title:"title",subtitle:"subtitle",link:"link",label:"label",ul:"ul",caption:"caption"},h={increase:"increase",decrease:"decrease",cancel:"cancel",accept:"accept",split:"split"},x={active:"active",adaptive:"adaptive",first:"first",focus:"focus",pending:"pending",last:"last",draggable:"draggable",filterable:"filterable",grouping:"grouping",selected:"selected",highlighted:"highlighted",disabled:"disabled",hidden:"hidden",highlight:"highlight",invalid:"invalid",loading:"loading",required:"required",checked:"checked",empty:"empty",scrollable:"scrollable",sorted:"sorted",sort:"sort",sticky:"sticky",stretched:"stretched",order:"order",alt:"alt",edit:"edit",template:"template",shown:"shown",horizontal:"horizontal",vertical:"vertical",fullscreen:"fullscreen",bottom:"bottom"},b={prefix:"animation",child:"child",relative:"relative",slide:"slide",appear:"appear",active:"active",enter:"enter",exit:"exit",pushRight:"push-right",pushLeft:"push-left",pushDown:"push-down",pushUp:"push-up",expandVertical:"expand-vertical",expandHorizontal:"expand-horizontal",fade:"fade",zoomIn:"zoom-in",zoomOut:"zoom-out",slideIn:"slide-in",slideDown:"slide-down",slideUp:"slide-up",slideRight:"slide-right",slideLeft:"slide-left",revealVertical:"reveal-vertical",revealHorizontal:"reveal-horizontal","animation-container":"animation-container","animation-container-shown":"animation-container-shown","animation-container-relative":"animation-container-relative","animation-container-fixed":"animation-container-fixed","child-animation-container":"child-animation-container"},i={input:"input",inner:"inner",spin:"spin",spinner:"spinner",maskedtextbox:"maskedtextbox",radio:"radio",textbox:"textbox",prefix:"prefix",suffix:"suffix"},g={week:"week",weekdays:"weekdays",weekend:"weekend",month:"month",year:"year",decade:"decade",century:"century",number:"number",navigation:"navigation",marker:"marker",now:"now",range:"range",today:"today",other:"other",date:"date",time:"time",selector:"selector",timeselector:"timeselector"},v={prefix:"icon",svg:"svg",i:"i",color:"color",flipH:"flip-h",flipV:"flip-v"},w={label:"label",text:"text",floatingLabel:"floating-label",container:"container",hint:"form-hint",error:"form-error"},k={form:"form",fieldset:"fieldset",legend:"legend",separator:"separator",field:"field"},y={prefix:"popup"},a={prefix:"grid",ariaRoot:"aria-root",tableWrap:"table-wrap",master:"master",column:"column",cell:"cell",cellInner:"cell-inner",row:"row",group:"group",hierarchy:"hierarchy",detail:"detail",noRecords:"norecords",pager:"pager"},P={drop:"drop",drag:"drag",hint:"hint",vertical:"v",horizontal:"h",clue:"clue",reorder:"reorder"},$=`${e.prefix}-${i.input}`,z=`${e.prefix}-${t.calendar}`,M=`${e.prefix}-${t.maskedtextbox}`,R=`${e.prefix}-${i.radio}`,L=`${e.prefix}-${o.button}`,I=`${e.prefix}-${t.menu}`,D=`${e.prefix}-${r.picker}`,S=`${e.prefix}-${t.dropdownlist}`,U=`${e.prefix}-${t.combobox}`,j=`${e.prefix}-${a.prefix}`,H={base:e,actions:h,animation:b,sizeMap:l,components:t,cssUtils:n,directionMap:u,fillModeMap:s,themeColorMap:c,roundedMap:d,orientationMap:p,elements:o,states:x,dimensions:f,containers:r,cursor:m,inputs:i,dateInputs:g,labels:w,forms:k,popup:y,icon:v,grid:a};exports.actions=h;exports.animationStyles=b;exports.base=e;exports.buttonPrefix=L;exports.calendarPrefix=z;exports.comboBoxPrefix=U;exports.components=t;exports.containers=r;exports.cssUtils=n;exports.cursor=m;exports.dateInputs=g;exports.ddbPrefix=I;exports.dimensions=f;exports.directionMap=u;exports.dropDownListPrefix=S;exports.elements=o;exports.fillModeMap=s;exports.forms=k;exports.grid=a;exports.gridPrefix=j;exports.gridRowReorder=P;exports.icon=v;exports.inputPrefix=$;exports.inputs=i;exports.jsonTheme=H;exports.labels=w;exports.maskedPrefix=M;exports.orientationMap=p;exports.pickerPrefix=D;exports.popup=y;exports.radioPrefix=R;exports.roundedMap=d;exports.sizeMap=l;exports.states=x;exports.themeColorMap=c;
|