@telia-ace/widget-components-area 1.1.2-rc.1 → 1.1.2-rc.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.
|
@@ -6,7 +6,7 @@ import { genericComponentStyling as T, Component as v } from "@telia-ace/widget-
|
|
|
6
6
|
import { TransitionComponent as q, Grid as P, useComponentDescriptor as F, useRenderState as H, useContext as I, useProperties as J, useChildren as K, useContainer as Q, useScroll as U, createEmptyComponent as V, ColumnContext as w, filterCssProps as X, Dropdown as Y, DrawerAnimationType as Z, Drawer as _, Button as ee, filterCssPropsStyle as te, paddedBorderTabStyle as ne, Text as re, SymbolBadge as oe } from "@telia-ace/widget-ui";
|
|
7
7
|
import { appendClassNames as y, Logger as ie } from "@telia-ace/widget-utilities";
|
|
8
8
|
import { forwardRef as se, useCallback as ae } from "react";
|
|
9
|
-
import { A as l } from "./index-
|
|
9
|
+
import { A as l } from "./index-ca543402.mjs";
|
|
10
10
|
const le = se(
|
|
11
11
|
({ children: e, className: t, renderState: o, animation: i, ...f }, s) => o ? /* @__PURE__ */ n(
|
|
12
12
|
q,
|
|
@@ -30,17 +30,17 @@ const le = se(
|
|
|
30
30
|
}
|
|
31
31
|
) : null
|
|
32
32
|
), ce = m(P)`
|
|
33
|
-
|
|
34
|
-
|
|
33
|
+
${T}
|
|
34
|
+
${(e) => !!e.animationCss && e.animationCss}
|
|
35
35
|
${(e) => !!e.scrollableCss && e.scrollableCss}
|
|
36
36
|
text-size-adjust: 100%;
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
37
|
+
input::-ms-clear {
|
|
38
|
+
display: none;
|
|
39
|
+
}
|
|
40
|
+
${(e) => e.hidden && e["data-state"] === "exited" && S`
|
|
41
|
+
visibility: collapse;
|
|
42
|
+
pointer-events: none;
|
|
43
|
+
`};
|
|
44
44
|
`, we = ({ className: e, ...t }) => {
|
|
45
45
|
const { name: o } = F(), i = H(), f = I(), s = J(), a = K(), d = Q(), { gap: A = "0" } = f, {
|
|
46
46
|
columns: h = 1,
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("react/jsx-runtime"),w=require("@emotion/react"),u=require("@emotion/styled"),c=require("@telia-ace/widget-core"),f=require("@telia-ace/widget-types-grid"),t=require("@telia-ace/widget-ui"),h=require("@telia-ace/widget-utilities"),v=require("react"),d=require("./index-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("react/jsx-runtime"),w=require("@emotion/react"),u=require("@emotion/styled"),c=require("@telia-ace/widget-core"),f=require("@telia-ace/widget-types-grid"),t=require("@telia-ace/widget-ui"),h=require("@telia-ace/widget-utilities"),v=require("react"),d=require("./index-d68cb848.js"),G=v.forwardRef(({children:e,className:n,renderState:i,animation:o,...C},a)=>i?r.jsx(t.TransitionComponent,{mountOnEnter:i!==c.WidgetRenderState.hidden,timeout:200,in:i===c.WidgetRenderState.open,transitions:o,unmountOnExit:i===c.WidgetRenderState.closed,children:(l,m)=>r.jsx(L,{...C,animationCss:m,"data-state":l,ref:a,className:h.appendClassNames("humany-animated-area",n),children:e})}):null),L=u(t.Grid)`
|
|
2
|
+
${f.genericComponentStyling}
|
|
3
|
+
${e=>!!e.animationCss&&e.animationCss}
|
|
4
4
|
${e=>!!e.scrollableCss&&e.scrollableCss}
|
|
5
5
|
text-size-adjust: 100%;
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
6
|
+
input::-ms-clear {
|
|
7
|
+
display: none;
|
|
8
|
+
}
|
|
9
|
+
${e=>e.hidden&&e["data-state"]==="exited"&&w.css`
|
|
10
|
+
visibility: collapse;
|
|
11
|
+
pointer-events: none;
|
|
12
|
+
`};
|
|
13
13
|
`,U=({className:e,...n})=>{const{name:i}=t.useComponentDescriptor(),o=t.useRenderState(),C=t.useContext(),a=t.useProperties(),l=t.useChildren(),m=t.useContainer(),{gap:T="0"}=C,{columns:x=1,animation:g="none",scrollable:q=!1,mode:p=d.AreaMode.Static,trigger:A={},fullScreen:R,header:P,...M}=a,{size:W=24,symbol:b,label:$,ariaLabel:D,...N}=A,[z,B]=t.useScroll(q),O=v.useCallback(s=>{const{events:E}=m.get("$widget");return E.dispatch("widget:area-rendered",{name:i,properties:a,element:s}),B.current=s,s},[a,o]);if(!l.length)return t.createEmptyComponent(m,{...n,className:h.appendClassNames(e,"humany-area")});const j={...n,className:h.appendClassNames(e,"humany-area",`humany-area-${i}`),scrollableCss:z,...M,columns:x,gap:T,renderState:o,animation:g,hidden:o===c.WidgetRenderState.hidden,ref:O},y=(()=>g!=="none"?r.jsx(t.ColumnContext.Provider,{value:x,children:r.jsx(G,{...j,children:l.map(s=>r.jsx(f.Component,{id:s.id,branch:"default"},s.id))})}):o===c.WidgetRenderState.closed?null:r.jsx(t.ColumnContext.Provider,{value:x,children:r.jsx(I,{...j,children:l.map(s=>r.jsx(f.Component,{id:s.id,branch:"default"},s.id))})}))();if(p===d.AreaMode.Static)return y;const S=r.jsxs(k,{className:"humany-area-trigger",title:D,...t.filterCssProps(N),children:[$&&r.jsx(F,{children:$}),b&&r.jsx(H,{symbol:b,size:W})]});if(p===d.AreaMode.Dropdown)return r.jsx(t.Dropdown,{trigger:S,children:y});if(p===d.AreaMode.Drawer){const s=Object.values(t.DrawerAnimationType).includes(g)&&{type:g}||void 0;return r.jsx(t.Drawer,{header:P,animation:s,fullScreen:R,trigger:S,children:y})}return p===d.AreaMode.Modal&&h.Logger.warn("modal area not implemented"),null},k=u(t.Button)`
|
|
14
14
|
display: flex;
|
|
15
15
|
align-items: inherit;
|
|
@@ -1,7 +1,12 @@
|
|
|
1
1
|
import { createReactComponent as t } from "@telia-ace/widget-ui";
|
|
2
2
|
var o = /* @__PURE__ */ ((r) => (r.Static = "static", r.Drawer = "drawer", r.Dropdown = "dropdown", r.Modal = "modal", r))(o || {});
|
|
3
|
-
const p = (r) => t(
|
|
4
|
-
|
|
3
|
+
const p = (r) => t(
|
|
4
|
+
r,
|
|
5
|
+
"area",
|
|
6
|
+
import("./area-2730550b.mjs"),
|
|
7
|
+
(a) => {
|
|
8
|
+
}
|
|
9
|
+
);
|
|
5
10
|
export {
|
|
6
11
|
o as A,
|
|
7
12
|
p as a
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const t=require("@telia-ace/widget-ui");var r=(e=>(e.Static="static",e.Drawer="drawer",e.Dropdown="dropdown",e.Modal="modal",e))(r||{});const o=e=>t.createReactComponent(e,"area",Promise.resolve().then(()=>require("./area-
|
|
1
|
+
"use strict";const t=require("@telia-ace/widget-ui");var r=(e=>(e.Static="static",e.Drawer="drawer",e.Dropdown="dropdown",e.Modal="modal",e))(r||{});const o=e=>t.createReactComponent(e,"area",Promise.resolve().then(()=>require("./area-b1abdc0c.js")),n=>{});exports.AreaComponent=o;exports.AreaMode=r;
|
package/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const e=require("./index-
|
|
1
|
+
"use strict";const e=require("./index-d68cb848.js");require("@telia-ace/widget-ui");module.exports=e.AreaComponent;
|
package/index.mjs
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@telia-ace/widget-components-area",
|
|
3
|
-
"version": "1.1.2-rc.
|
|
3
|
+
"version": "1.1.2-rc.2",
|
|
4
4
|
"main": "./index.js",
|
|
5
5
|
"types": "./index.d.ts",
|
|
6
6
|
"exports": {
|
|
@@ -10,10 +10,10 @@
|
|
|
10
10
|
}
|
|
11
11
|
},
|
|
12
12
|
"dependencies": {
|
|
13
|
-
"@telia-ace/widget-core": "^1.1.2-rc.
|
|
14
|
-
"@telia-ace/widget-types-grid": "^1.1.2-rc.
|
|
15
|
-
"@telia-ace/widget-ui": "^1.1.2-rc.
|
|
16
|
-
"@telia-ace/widget-utilities": "^1.1.2-rc.
|
|
13
|
+
"@telia-ace/widget-core": "^1.1.2-rc.2",
|
|
14
|
+
"@telia-ace/widget-types-grid": "^1.1.2-rc.2",
|
|
15
|
+
"@telia-ace/widget-ui": "^1.1.2-rc.2",
|
|
16
|
+
"@telia-ace/widget-utilities": "^1.1.2-rc.2",
|
|
17
17
|
"@webprovisions/platform": "^1.1.3"
|
|
18
18
|
},
|
|
19
19
|
"peerDependencies": {
|