@telia-ace/knowledge-widget-components-tag-list 1.3.41-rc.1 → 1.3.41

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/index.js CHANGED
@@ -1 +1 @@
1
- "use strict";const d=require("@telia-ace/knowledge-data-client"),g=require("@telia-ace/knowledge-widget-core"),p=require("@telia-ace/knowledge-widget-ui"),b=s=>p.createReactComponent(s,"tag-list",Promise.resolve().then(()=>require("./tag-list-bd4c0029.js")),t=>{const{events:o}=s.get("$widget"),[c,u]=g.createEventSubscriber(o);t.actions.create("fetch",({items:e=[]})=>t.actions.dispatch("fetched",{items:e,loading:!0})),t.actions.create("fetched",e=>t.writeProperties({...e,loading:!1}));const a=(e={})=>{t.writeProperties({loading:!0,error:void 0}),t.actions.dispatch("fetch",e)};return s.getAsync("router").then(e=>{const{params:i}=e.getRouteData();a(i)}),c("router:changed",(e,{current:i})=>{a(i.routeData.params)}),()=>{u()}}).then(()=>g.extendComponent(s,"tag-list",t=>{t.actions.watch("tag-list.fetch",(o,c)=>d.DataClient.getInstance(s).then(u=>{const{static:a=!1,rootTagLabel:e=""}=t.properties(),{phrase:i,guideCategory:h,tag:l}=o;return u.fetch(a?d.DataType.Tags:d.DataType.TagsOnGuides,{searchPhrase:i,categories:h,tagId:l}).then((n=[])=>{if(a){const r=n.findIndex(f=>f.id==="0");r>-1&&n.unshift(n.splice(r,1)[0])}return c({items:n.map(r=>(r.id==="0"&&(r.title=e),r))})}).catch(n=>c({items:[]}))}))}));module.exports=b;
1
+ "use strict";const d=require("@telia-ace/knowledge-data-client"),g=require("@telia-ace/knowledge-widget-core"),p=require("@telia-ace/knowledge-widget-ui"),b=s=>p.createReactComponent(s,"tag-list",Promise.resolve().then(()=>require("./tag-list-sQhApKLE.js")),t=>{const{events:o}=s.get("$widget"),[c,u]=g.createEventSubscriber(o);t.actions.create("fetch",({items:e=[]})=>t.actions.dispatch("fetched",{items:e,loading:!0})),t.actions.create("fetched",e=>t.writeProperties({...e,loading:!1}));const a=(e={})=>{t.writeProperties({loading:!0,error:void 0}),t.actions.dispatch("fetch",e)};return s.getAsync("router").then(e=>{const{params:i}=e.getRouteData();a(i)}),c("router:changed",(e,{current:i})=>{a(i.routeData.params)}),()=>{u()}}).then(()=>g.extendComponent(s,"tag-list",t=>{t.actions.watch("tag-list.fetch",(o,c)=>d.DataClient.getInstance(s).then(u=>{const{static:a=!1,rootTagLabel:e=""}=t.properties(),{phrase:i,guideCategory:h,tag:l}=o;return u.fetch(a?d.DataType.Tags:d.DataType.TagsOnGuides,{searchPhrase:i,categories:h,tagId:l}).then((n=[])=>{if(a){const r=n.findIndex(f=>f.id==="0");r>-1&&n.unshift(n.splice(r,1)[0])}return c({items:n.map(r=>(r.id==="0"&&(r.title=e),r))})}).catch(n=>c({items:[]}))}))}));module.exports=b;
package/index.mjs CHANGED
@@ -4,7 +4,7 @@ import { createReactComponent as b } from "@telia-ace/knowledge-widget-ui";
4
4
  const w = (a) => b(
5
5
  a,
6
6
  "tag-list",
7
- import("./tag-list-d143c7b3.mjs"),
7
+ import("./tag-list-D1l6YG6m.mjs"),
8
8
  (e) => {
9
9
  const { events: o } = a.get("$widget"), [n, u] = l(o);
10
10
  e.actions.create("fetch", ({ items: t = [] }) => e.actions.dispatch("fetched", {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@telia-ace/knowledge-widget-components-tag-list",
3
- "version": "1.3.41-rc.1",
3
+ "version": "1.3.41",
4
4
  "main": "./index.js",
5
5
  "types": "./index.d.ts",
6
6
  "exports": {
@@ -10,11 +10,11 @@
10
10
  }
11
11
  },
12
12
  "dependencies": {
13
- "@telia-ace/knowledge-widget-core": "^1.3.41-rc.1",
14
- "@telia-ace/knowledge-data-client": "^1.3.41-rc.1",
15
- "@telia-ace/knowledge-widget-ui": "^1.3.41-rc.1",
16
- "@telia-ace/widget-utilities": "^1.3.41-rc.1",
17
- "@telia-ace/knowledge-widget-component-utilities": "^1.3.41-rc.1",
13
+ "@telia-ace/knowledge-widget-core": "^1.3.41",
14
+ "@telia-ace/knowledge-data-client": "^1.3.41",
15
+ "@telia-ace/knowledge-widget-ui": "^1.3.41",
16
+ "@telia-ace/widget-utilities": "^1.3.41",
17
+ "@telia-ace/knowledge-widget-component-utilities": "^1.3.41",
18
18
  "@webprovisions/platform": "^1.1.4"
19
19
  },
20
20
  "peerDependencies": {
@@ -2,7 +2,7 @@ import { jsx as r, jsxs as j } from "react/jsx-runtime";
2
2
  import { css as h } from "@emotion/react";
3
3
  import a from "@emotion/styled";
4
4
  import { initialRouteFallback as A } from "@telia-ace/knowledge-widget-component-utilities";
5
- import { useProperties as B, useContainer as R, useRouteData as F, createEmptyComponent as M, Loader as N, ItemList as O, contentBox as P, itemList as D, loadingOpacity as E, TextLink as $, borderTabStyle as x, Text as U, SymbolBadge as q } from "@telia-ace/knowledge-widget-ui";
5
+ import { useProperties as B, useContainer as R, useRouteData as F, createEmptyComponent as M, Loader as N, contentBox as O, itemList as P, loadingOpacity as D, ItemList as E, borderTabStyle as $, TextLink as x, Text as U, SymbolBadge as q } from "@telia-ace/knowledge-widget-ui";
6
6
  import { appendClassNames as y } from "@telia-ace/widget-utilities";
7
7
  const G = (e, t, o) => e && o ? /* @__PURE__ */ r(b, { symbol: o, size: 18 }) : t ? /* @__PURE__ */ r(b, { symbol: t, size: 18 }) : null, oe = ({ className: e, ...t }) => {
8
8
  const {
@@ -67,10 +67,10 @@ const G = (e, t, o) => e && o ? /* @__PURE__ */ r(b, { symbol: o, size: 18 }) :
67
67
  children: !s && /* @__PURE__ */ r(N, { loading: l })
68
68
  }
69
69
  );
70
- }, H = a(O)`
70
+ }, H = a(E)`
71
+ ${O}
71
72
  ${P}
72
73
  ${D}
73
- ${E}
74
74
  justify-content: flex-start;
75
75
  padding: ${(e) => {
76
76
  var t;
@@ -90,7 +90,7 @@ const G = (e, t, o) => e && o ? /* @__PURE__ */ r(b, { symbol: o, size: 18 }) :
90
90
  }} 0;
91
91
  }
92
92
  }
93
- `, J = a($)`
93
+ `, J = a(x)`
94
94
  padding: 8px 15px;
95
95
  background-color: ${(e) => {
96
96
  var t, o;
@@ -107,7 +107,7 @@ const G = (e, t, o) => e && o ? /* @__PURE__ */ r(b, { symbol: o, size: 18 }) :
107
107
  color: #ffffff;
108
108
 
109
109
  &:focus-visible {
110
- ${x}
110
+ ${$}
111
111
  padding: 6px 15px;
112
112
  background-color: transparent;
113
113
  }
@@ -120,7 +120,7 @@ const G = (e, t, o) => e && o ? /* @__PURE__ */ r(b, { symbol: o, size: 18 }) :
120
120
  }};
121
121
  }
122
122
  }
123
- `, K = a($)`
123
+ `, K = a(x)`
124
124
  border: 1px solid
125
125
  ${(e) => {
126
126
  var t;
@@ -145,7 +145,7 @@ const G = (e, t, o) => e && o ? /* @__PURE__ */ r(b, { symbol: o, size: 18 }) :
145
145
  }
146
146
 
147
147
  &:focus-visible {
148
- ${x}
148
+ ${$}
149
149
  border-radius: 1em;
150
150
  }
151
151
 
File without changes