@bikdotai/bik-component-library 0.0.435 → 0.0.436-beta-sidebar
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/cjs/assets/icons/bik_ai_stars_icon.svg.js +1 -0
- package/dist/cjs/components/bik-layout/BikSidebar.js +1 -1
- package/dist/cjs/components/bik-layout/MockMenus.d.ts +0 -1
- package/dist/cjs/components/tag/Tag.js +1 -1
- package/dist/cjs/components/tag/Tag.styled.js +1 -1
- package/dist/cjs/components/tag/model.d.ts +3 -1
- package/dist/cjs/components/tag/model.js +1 -1
- package/dist/cjs/components/tag/themes.js +1 -1
- package/dist/esm/assets/icons/bik_ai_stars_icon.svg.js +1 -0
- package/dist/esm/components/bik-layout/BikSidebar.js +1 -1
- package/dist/esm/components/bik-layout/MockMenus.d.ts +0 -1
- package/dist/esm/components/tag/Tag.js +1 -1
- package/dist/esm/components/tag/Tag.styled.js +1 -1
- package/dist/esm/components/tag/model.d.ts +3 -1
- package/dist/esm/components/tag/model.js +1 -1
- package/dist/esm/components/tag/themes.js +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";function e(e){if(e&&e.__esModule)return e;var a=Object.create(null);return e&&Object.keys(e).forEach((function(l){if("default"!==l){var t=Object.getOwnPropertyDescriptor(e,l);Object.defineProperty(a,l,t.get?t:{enumerable:!0,get:function(){return e[l]}})}})),a.default=e,Object.freeze(a)}Object.defineProperty(exports,"__esModule",{value:!0});var a,l=e(require("react"));function t(){return t=Object.assign?Object.assign.bind():function(e){for(var a=1;a<arguments.length;a++){var l=arguments[a];for(var t in l)Object.prototype.hasOwnProperty.call(l,t)&&(e[t]=l[t])}return e},t.apply(this,arguments)}var r=e=>l.createElement("svg",t({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 16"},e),a||(a=l.createElement("path",{fill:"currentColor",d:"M11.216 1.025a.133.133 0 0 1 .235 0l.743 1.392a.134.134 0 0 0 .055.055l1.392.743a.133.133 0 0 1 0 .235l-1.392.743a.134.134 0 0 0-.055.054L11.45 5.64a.133.133 0 0 1-.235 0l-.742-1.393a.133.133 0 0 0-.055-.054L9.027 3.45a.133.133 0 0 1 0-.235l1.392-.743a.133.133 0 0 0 .055-.055l.742-1.392Zm-4.124 5.16a.133.133 0 0 0 .055.055l3.077 1.641a.133.133 0 0 1 0 .236l-3.077 1.64a.133.133 0 0 0-.055.056l-1.64 3.077a.133.133 0 0 1-.236 0l-1.64-3.077a.133.133 0 0 0-.056-.055L.443 8.117a.133.133 0 0 1 0-.236l3.077-1.64a.133.133 0 0 0 .055-.055l1.641-3.077a.133.133 0 0 1 .235 0l1.641 3.077Zm.299 1.932a.133.133 0 0 0 0-.236l-1.23-.655a.133.133 0 0 1-.054-.055l-.656-1.23a.133.133 0 0 0-.235 0l-.655 1.23a.133.133 0 0 1-.055.055l-1.23.655a.133.133 0 0 0 0 .236l1.23.655a.133.133 0 0 1 .055.055l.655 1.23c.05.093.185.093.235 0l.656-1.23a.133.133 0 0 1 .055-.055l1.229-.655Zm5.756 2.79a.134.134 0 0 1-.055-.055l-.974-1.827a.133.133 0 0 0-.235 0l-.975 1.827a.133.133 0 0 1-.054.055l-1.827.975a.133.133 0 0 0 0 .235l1.827.974a.132.132 0 0 1 .054.055l.975 1.827c.05.094.185.094.235 0l.974-1.827a.133.133 0 0 1 .055-.055l1.827-.974a.133.133 0 0 0 0-.236l-1.827-.974Z"})));exports.default=r;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),i=require("../../assets/icons/Bik_logo.svg.js"),n=require("react"),t=require("../../constants/Theme.js"),o=require("../navigation-hyperlink/NavigationHyperlink.js"),s=require("./SidebarPopup.js"),l=require("./SidebarStyles.js"),d=require("./SimpleSidebar.js");const
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),i=require("../../assets/icons/Bik_logo.svg.js"),n=require("react"),t=require("../../constants/Theme.js"),o=require("../navigation-hyperlink/NavigationHyperlink.js"),s=require("./SidebarPopup.js"),l=require("./SidebarStyles.js"),d=require("./SimpleSidebar.js");const a=i=>{const{icon:n,isActive:o,activeStateIcon:s,hoverStateIcon:l,isHovered:d}=i,a=n,r=s,u=l;return e.jsx(e.Fragment,{children:o?e.jsx(r,{width:20,height:20}):d?e.jsx(u,{width:20,height:20,color:t.COLORS.surface.standard}):e.jsx(a,{width:20,height:20,color:t.COLORS.surface.standard})})};exports.BikSidebar=t=>{const{logoSvg:r,allMenuList:u,activeMainMenu:c,activeSubMenu:v,router:g,onClickingMainMenu:h,onClickingSubMenu:m,onClickingAccessUpgradePanel:p,onClickingPopupMenuItem:j,popupMinHeight:y,isNewSidebar:S}=t,[b,k]=n.useState(c),[x,w]=n.useState(),[M,N]=n.useState(v),[f,O]=n.useState(!1),[C,L]=n.useState(),[I,B]=n.useState(),[E,q]=n.useState();n.useEffect((()=>{k(c)}),[c]),n.useEffect((()=>{N(v)}),[v]);const H=e=>{var i,n;if(w(void 0),L(void 0),"popup"==(null==e?void 0:e.layout)){const i=A();i&&B(i),L(e)}else{const t=document.getElementById((null===(n=null===(i=e.displayName)||void 0===i?void 0:i.split(" "))||void 0===n?void 0:n.join(""))||e.key.toString());if(t){const e=t.getBoundingClientRect().top;q(e)}w(e)}},P=(i,n)=>{var t,o,s,l,d,r;return e.jsxs("div",Object.assign({id:(null===(o=null===(t=i.displayName)||void 0===t?void 0:t.split(" "))||void 0===o?void 0:o.join(""))||i.key.toString(),className:"main--sidebar",onClick:()=>(e=>{var i;"popup"!==(null==e?void 0:e.layout)&&(L(void 0),w(void 0),O(!0),k(e),!e.path&&h(e),(null===(i=null==e?void 0:e.children)||void 0===i?void 0:i.length)?N(null==e?void 0:e.children[0]):N({}),w(void 0),setTimeout((()=>{O(!1)}),1e3))})(i),onMouseEnter:()=>{!f&&H(i)},onMouseOver:()=>{!f&&H(i)},onMouseLeave:()=>{var e;(null===(e=null==i?void 0:i.children)||void 0===e?void 0:e.length)||(w(void 0),L(void 0))},onFocus:()=>{console.log(";")},"aria-hidden":"true"},{children:[i.isNew&&e.jsx("div",Object.assign({className:"new-tag"},{children:" NEW"})),e.jsxs("div",Object.assign({id:(null===(l=null===(s=i.displayName)||void 0===s?void 0:s.split(" "))||void 0===l?void 0:l.join(""))+"_sub"||i.key.toString()+"_sub",className:`sidebar-menu-item ${(null==b?void 0:b.key)==i.key?" main-menu-active-class":""} ${i.isLastSticky?"sticky-menu-int":""} ${i.is2ndLastSticky?"sticky-menu":""}\n\t\t\t\t\t${i.key==(null==x?void 0:x.key)?"sidebar-menu-item-hover":""}\`}\n\t\t\t\t\t${i.isNew?"new-menu-item":""}`},{children:[e.jsx(a,{icon:i.icon,isActive:i.key==(null==b?void 0:b.key),activeStateIcon:null!==(d=i.activeIcon)&&void 0!==d?d:{},hoverStateIcon:null!==(r=i.hoverIcon)&&void 0!==r?r:{},isHovered:i.key==(null==x?void 0:x.key)}),e.jsx("div",Object.assign({className:"menu-item-container"},{children:e.jsx("p",Object.assign({className:"menu-item-text "+((null==i?void 0:i.key)===(null==b?void 0:b.key)?"active-menu-item-text":"")},{children:i.displayName}))}))]}),n)]}),n)};n.useEffect((()=>{const e=()=>{const e=A();e&&B(e),_()};return window.addEventListener("resize",e),()=>{window.removeEventListener("resize",e)}}),[]);const _=()=>{const e=document.getElementById("_sub-menu"),i=null==e?void 0:e.getBoundingClientRect().height;i&&q(window.innerHeight-i)},A=()=>{var e,i;if(C){const n=(null===(i=null===(e=C.displayName)||void 0===e?void 0:e.split(" "))||void 0===i?void 0:i.join(""))+"_sub"||C.key.toString()+"_sub",t=document.getElementById(n);if(t){const e=t.getBoundingClientRect();let i=e.top;const n=null!=y?y:320;return e.bottom+n>window.innerHeight&&(i-=e.bottom+n-window.innerHeight),i}return null}};return e.jsxs(l.SideBarContainer,Object.assign({onMouseLeave:()=>{w(void 0)}},{children:[e.jsx("div",Object.assign({className:"bik-header-logo",onClick:()=>{},onKeyDown:()=>{},"aria-hidden":"true"},{children:r||e.jsx(i.default,{})})),e.jsx(l.SibeBarMenuItem,{children:null==u?void 0:u.map(((i,t)=>{var l,a;return e.jsxs(n.Fragment,{children:[i.path?e.jsx(o.NavigationHyperlink,Object.assign({href:i.path,router:g},{children:P(i,t)})):P(i,t),e.jsxs(e.Fragment,{children:["popup"===i.layout&&(null===(l=null==C?void 0:C.children)||void 0===l?void 0:l.length)&&e.jsx(s.SidebarPopup,{top:null!=I?I:void 0,menuList:null==C?void 0:C.children,onClickingPopupMenu:e=>{j&&j(e),L(void 0)},onMouseLeaveOnMenu:()=>L(void 0)}),(null===(a=null==x?void 0:x.children)||void 0===a?void 0:a.length)&&e.jsx(d.SimpleSidebar,{menuList:null==x?void 0:x.children,activeMenu:M,onMouseLeaveOnMenu:()=>w(void 0),left:S?92:88,postion:"fixed",header:x.displayName,theme:"brand",router:g,showAccessUpgradePanel:x.showAccessUpgradePanel,onMenuClick:(e,i)=>{N(e),k(x),w(void 0),L(void 0),i&&m(e)},onUpgrade:p,top:S&&E||0,isNewSidebar:S})]})]},t)}))})]}))};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),i=require("
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),i=require("../../assets/icons/bik_ai_stars_icon.svg.js"),a=require("react"),r=require("../TypographyStyle.js"),n=require("./model.js"),t=require("./Tag.styled.js"),s=require("./themes.js");function c(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var l=c(a);const o=a=>{let{tagText:c,LeadingIcon:o,TrailingIcon:d,onLeadingIconClicked:g,leadingIconId:u,trailingIconId:j,onTrailingIconClicked:p,theme:b="light",type:y="neutral",variant:h="regular",version:m,cursor:v}=a;var T;let x=c,O=b,f=y;n.ValidTagTypeMap[h][y]||(f="neutral"),"circle"===h&&(O="dark","number"==typeof x&&x>99&&(x="99+"));const I={height:16,width:16,color:s.getTagIconColor(b,f),style:{display:"block"}},k=()=>"ai"!==y||o?o:i.default;return e.jsx(t.Tag,Object.assign({cursor:v,theme:O,type:y,variant:h,version:m},{children:e.jsxs("div",Object.assign({className:"container"},{children:[k()&&e.jsx("button",Object.assign({className:"icon-leading",onClick:g,id:`${u}-wrapper`||"leading-icon-wrapper"},{children:l.default.createElement(null!==(T=k())&&void 0!==T?T:"",Object.assign(Object.assign({},I),{id:u||"leading-icon"}))})),e.jsx(r.BodyCaption,Object.assign({className:"text"},{children:x})),d&&e.jsx("button",Object.assign({className:"icon-trailing",onClick:p,id:`${j}-wrapper`||"trailing-icon-wrapper"},{children:l.default.createElement(d,Object.assign(Object.assign({},I),{id:j||"trailing-icon"}))}))]}))}))};o.displayName="Tag",exports.Tag=o;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var c=require("@emotion/styled/base"),e=require("./themes.js");function l(c){return c&&"object"==typeof c&&"default"in c?c:{default:c}}const t=l(c).default("div","production"===process.env.NODE_ENV?{target:"e930jd90"}:{target:"e930jd90",label:"Tag"})("cursor:",(c=>{var e;return null!==(e=c.cursor)&&void 0!==e?e:"default"}),";",(c=>"regular"===c.variant?"display: block;\n\t\t min-height: 26px;\n\t\t":"min-height: 20px;")," .container{display:flex;align-items:center;gap:6px;padding:",(c=>e.getPadding(c.variant)),";background
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var c=require("@emotion/styled/base"),e=require("./themes.js");function l(c){return c&&"object"==typeof c&&"default"in c?c:{default:c}}const t=l(c).default("div","production"===process.env.NODE_ENV?{target:"e930jd90"}:{target:"e930jd90",label:"Tag"})("cursor:",(c=>{var e;return null!==(e=c.cursor)&&void 0!==e?e:"default"}),";",(c=>"regular"===c.variant?"display: block;\n\t\t min-height: 26px;\n\t\t":"min-height: 20px;")," .container{display:flex;align-items:center;gap:6px;padding:",(c=>e.getPadding(c.variant)),";background:",(c=>e.getBackgroundColor(c.theme,c.type)),";border-radius:",(c=>"regular"===c.variant?"4px":"12px"),";",(c=>"light"===c.theme&&`border: ${"2.0"===c.version?.5:1}px solid ${e.generateBorder(c.type)};`)," .text{color:",(c=>e.getTextColor(c.theme,c.type)),";}.icon-trailing{all:unset;display:flex;}.icon-leading{all:unset;display:flex;}}"+("production"===process.env.NODE_ENV?"":"/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIlRhZy5zdHlsZWQudHN4Il0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUU4QiIsImZpbGUiOiJUYWcuc3R5bGVkLnRzeCIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCBzdHlsZWQgZnJvbSAnQGVtb3Rpb24vc3R5bGVkJztcclxuaW1wb3J0IHsgZ2VuZXJhdGVCb3JkZXIsIGdldEJhY2tncm91bmRDb2xvciwgZ2V0UGFkZGluZywgZ2V0VGV4dENvbG9yLCB9IGZyb20gJy4vdGhlbWVzJztcclxuZXhwb3J0IGNvbnN0IFRhZyA9IHN0eWxlZC5kaXYgYFxuXHRjdXJzb3I6ICR7KHByb3BzKSA9PiB7IHZhciBfYTsgcmV0dXJuIChfYSA9IHByb3BzLmN1cnNvcikgIT09IG51bGwgJiYgX2EgIT09IHZvaWQgMCA/IF9hIDogJ2RlZmF1bHQnOyB9fTtcblx0JHsocHJvcHMpID0+IHByb3BzLnZhcmlhbnQgPT09ICdyZWd1bGFyJ1xyXG4gICAgPyBgZGlzcGxheTogYmxvY2s7XG5cdFx0ICAgICBtaW4taGVpZ2h0OiAyNnB4O1xuXHRcdGBcclxuICAgIDogYG1pbi1oZWlnaHQ6IDIwcHg7YH1cblx0LmNvbnRhaW5lciB7XG5cdFx0ZGlzcGxheTogZmxleDtcblx0XHRhbGlnbi1pdGVtczogY2VudGVyO1xuXHRcdGdhcDogNnB4O1xuXHRcdHBhZGRpbmc6ICR7KHByb3BzKSA9PiBnZXRQYWRkaW5nKHByb3BzLnZhcmlhbnQpfTtcblxuXHRcdGJhY2tncm91bmQ6ICR7KHByb3BzKSA9PiBnZXRCYWNrZ3JvdW5kQ29sb3IocHJvcHMudGhlbWUsIHByb3BzLnR5cGUpfTtcblxuXHRcdGJvcmRlci1yYWRpdXM6ICR7KHByb3BzKSA9PiAocHJvcHMudmFyaWFudCA9PT0gJ3JlZ3VsYXInID8gJzRweCcgOiAnMTJweCcpfTtcblxuXHRcdCR7KHByb3BzKSA9PiBwcm9wcy50aGVtZSA9PT0gJ2xpZ2h0JyAmJlxyXG4gICAgYGJvcmRlcjogJHtwcm9wcy52ZXJzaW9uID09PSAnMi4wJyA/IDAuNSA6IDF9cHggc29saWQgJHtnZW5lcmF0ZUJvcmRlcihwcm9wcy50eXBlKX07YH1cblxuXHRcdC50ZXh0IHtcblx0XHRcdGNvbG9yOiAkeyhwcm9wcykgPT4gZ2V0VGV4dENvbG9yKHByb3BzLnRoZW1lLCBwcm9wcy50eXBlKX07XG5cdFx0fVxuXG5cdFx0Lmljb24tdHJhaWxpbmcge1xuXHRcdFx0YWxsOiB1bnNldDtcblx0XHRcdGRpc3BsYXk6IGZsZXg7XG5cdFx0fVxuXG5cdFx0Lmljb24tbGVhZGluZyB7XG5cdFx0XHRhbGw6IHVuc2V0O1xuXHRcdFx0ZGlzcGxheTogZmxleDtcblx0XHR9XG5cdH1cbmA7XHJcbi8vIyBzb3VyY2VNYXBwaW5nVVJMPVRhZy5zdHlsZWQuanMubWFwIl19 */"));exports.Tag=t;
|
|
@@ -2,7 +2,7 @@ import React from 'react';
|
|
|
2
2
|
import { MouseEventHandler } from 'react';
|
|
3
3
|
export type TagTheme = 'light' | 'dark';
|
|
4
4
|
export type TagVariant = 'regular' | 'circle';
|
|
5
|
-
export type TagType = 'negative' | 'warning' | 'positive' | 'neutral' | 'white' | 'purple' | 'blue' | 'grey';
|
|
5
|
+
export type TagType = 'negative' | 'warning' | 'positive' | 'neutral' | 'white' | 'purple' | 'blue' | 'grey' | 'ai';
|
|
6
6
|
export declare const ValidTagTypeMap: {
|
|
7
7
|
regular: {
|
|
8
8
|
negative: boolean;
|
|
@@ -12,6 +12,7 @@ export declare const ValidTagTypeMap: {
|
|
|
12
12
|
white: boolean;
|
|
13
13
|
purple: boolean;
|
|
14
14
|
blue: boolean;
|
|
15
|
+
ai: boolean;
|
|
15
16
|
};
|
|
16
17
|
circle: {
|
|
17
18
|
negative: boolean;
|
|
@@ -20,6 +21,7 @@ export declare const ValidTagTypeMap: {
|
|
|
20
21
|
neutral: boolean;
|
|
21
22
|
blue: boolean;
|
|
22
23
|
grey: boolean;
|
|
24
|
+
ai: boolean;
|
|
23
25
|
};
|
|
24
26
|
};
|
|
25
27
|
export interface TagProps extends React.BaseHTMLAttributes<HTMLDivElement> {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.ValidTagTypeMap={regular:{negative:!0,warning:!0,positive:!0,neutral:!0,white:!0,purple:!0,blue:!0},circle:{negative:!0,warning:!0,positive:!0,neutral:!0,blue:!0,grey:!0}};
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.ValidTagTypeMap={regular:{negative:!0,warning:!0,positive:!0,neutral:!0,white:!0,purple:!0,blue:!0,ai:!0},circle:{negative:!0,warning:!0,positive:!0,neutral:!0,blue:!0,grey:!0,ai:!0}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var r=require("../../constants/Theme.js");const e={blue:{iconColor:{light:r.COLORS.content.blue,dark:r.COLORS.content.primaryInverse},textColor:{light:r.COLORS.content.blue,dark:r.COLORS.content.primaryInverse},border:r.COLORS.stroke.blue.lightAlt,backgroundColor:{light:r.COLORS.background.blue.light,dark:r.COLORS.content.blue,circle:r.COLORS.content.blue}},purple:{iconColor:{light:r.COLORS.background.inverseLight,dark:r.COLORS.content.primaryInverse},textColor:{light:r.COLORS.background.inverseLight,dark:r.COLORS.content.primaryInverse},border:r.COLORS.stroke.brandLightAlt,backgroundColor:{light:r.COLORS.background.brandLight,dark:r.COLORS.background.inverse,circle:r.COLORS.background.inverse}},negative:{iconColor:{light:r.COLORS.content.negative,dark:r.COLORS.content.primaryInverse},textColor:{light:r.COLORS.content.negative,dark:r.COLORS.content.primaryInverse},border:r.COLORS.stroke.negative.lightAlt,backgroundColor:{light:r.COLORS.background.negative.light,dark:r.COLORS.background.negative.vibrant,circle:r.COLORS.background.negative.vibrant}},positive:{iconColor:{light:r.COLORS.content.positive,dark:r.COLORS.content.primaryInverse},textColor:{light:r.COLORS.content.positive,dark:r.COLORS.content.primaryInverse},border:r.COLORS.stroke.positive.lightAlt,backgroundColor:{light:r.COLORS.background.positive.light,dark:r.COLORS.background.positive.vibrant,circle:r.COLORS.background.positive.vibrant}},warning:{iconColor:{light:r.COLORS.content.warning,dark:r.COLORS.content.primary},textColor:{light:r.COLORS.content.warning,dark:r.COLORS.content.primary},border:r.COLORS.stroke.warning.lightAlt,backgroundColor:{light:r.COLORS.background.warning.light,dark:r.COLORS.background.warning.vibrant,circle:r.COLORS.background.warning.vibrant}},neutral:{iconColor:{light:r.COLORS.content.secondary,dark:r.COLORS.content.primaryInverse},textColor:{light:r.COLORS.content.secondary,dark:r.COLORS.content.primaryInverse},border:r.COLORS.stroke.primary,backgroundColor:{light:r.COLORS.surface.subdued,dark:r.COLORS.background.inverse,circle:r.COLORS.background.inverseLight}},white:{iconColor:{light:r.COLORS.content.secondary,dark:r.COLORS.content.primaryInverse},textColor:{light:r.COLORS.content.secondary,dark:r.COLORS.content.primaryInverse},border:r.COLORS.stroke.primary,backgroundColor:{light:r.COLORS.surface.standard,dark:r.COLORS.background.inverse,circle:r.COLORS.background.inverseLight}},grey:{iconColor:{light:r.COLORS.content.secondary,dark:r.COLORS.content.primaryInverse},textColor:{light:r.COLORS.content.secondary,dark:r.COLORS.content.primaryInverse},border:r.COLORS.stroke.primary,backgroundColor:{light:r.COLORS.surface.subdued,dark:r.COLORS.content.secondary,circle:r.COLORS.content.secondary}}};exports.generateBorder=r=>e[r].border,exports.getBackgroundColor=(r,t)=>e[t].backgroundColor[r],exports.getPadding=r=>"regular"===r?"4px 8px":"2px 6px",exports.getTagIconColor=(r,t)=>e[t].iconColor[r],exports.getTextColor=(r,t)=>e[t].textColor[r];
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var r=require("../../constants/Theme.js");const e={blue:{iconColor:{light:r.COLORS.content.blue,dark:r.COLORS.content.primaryInverse},textColor:{light:r.COLORS.content.blue,dark:r.COLORS.content.primaryInverse},border:r.COLORS.stroke.blue.lightAlt,backgroundColor:{light:r.COLORS.background.blue.light,dark:r.COLORS.content.blue,circle:r.COLORS.content.blue}},purple:{iconColor:{light:r.COLORS.background.inverseLight,dark:r.COLORS.content.primaryInverse},textColor:{light:r.COLORS.background.inverseLight,dark:r.COLORS.content.primaryInverse},border:r.COLORS.stroke.brandLightAlt,backgroundColor:{light:r.COLORS.background.brandLight,dark:r.COLORS.background.inverse,circle:r.COLORS.background.inverse}},negative:{iconColor:{light:r.COLORS.content.negative,dark:r.COLORS.content.primaryInverse},textColor:{light:r.COLORS.content.negative,dark:r.COLORS.content.primaryInverse},border:r.COLORS.stroke.negative.lightAlt,backgroundColor:{light:r.COLORS.background.negative.light,dark:r.COLORS.background.negative.vibrant,circle:r.COLORS.background.negative.vibrant}},positive:{iconColor:{light:r.COLORS.content.positive,dark:r.COLORS.content.primaryInverse},textColor:{light:r.COLORS.content.positive,dark:r.COLORS.content.primaryInverse},border:r.COLORS.stroke.positive.lightAlt,backgroundColor:{light:r.COLORS.background.positive.light,dark:r.COLORS.background.positive.vibrant,circle:r.COLORS.background.positive.vibrant}},warning:{iconColor:{light:r.COLORS.content.warning,dark:r.COLORS.content.primary},textColor:{light:r.COLORS.content.warning,dark:r.COLORS.content.primary},border:r.COLORS.stroke.warning.lightAlt,backgroundColor:{light:r.COLORS.background.warning.light,dark:r.COLORS.background.warning.vibrant,circle:r.COLORS.background.warning.vibrant}},neutral:{iconColor:{light:r.COLORS.content.secondary,dark:r.COLORS.content.primaryInverse},textColor:{light:r.COLORS.content.secondary,dark:r.COLORS.content.primaryInverse},border:r.COLORS.stroke.primary,backgroundColor:{light:r.COLORS.surface.subdued,dark:r.COLORS.background.inverse,circle:r.COLORS.background.inverseLight}},white:{iconColor:{light:r.COLORS.content.secondary,dark:r.COLORS.content.primaryInverse},textColor:{light:r.COLORS.content.secondary,dark:r.COLORS.content.primaryInverse},border:r.COLORS.stroke.primary,backgroundColor:{light:r.COLORS.surface.standard,dark:r.COLORS.background.inverse,circle:r.COLORS.background.inverseLight}},grey:{iconColor:{light:r.COLORS.content.secondary,dark:r.COLORS.content.primaryInverse},textColor:{light:r.COLORS.content.secondary,dark:r.COLORS.content.primaryInverse},border:r.COLORS.stroke.primary,backgroundColor:{light:r.COLORS.surface.subdued,dark:r.COLORS.content.secondary,circle:r.COLORS.content.secondary}},ai:{iconColor:{light:r.COLORS.content.primaryInverse,dark:r.COLORS.content.primaryInverse},textColor:{light:r.COLORS.content.primaryInverse,dark:r.COLORS.content.primaryInverse},border:"none",backgroundColor:{light:r.COLORS.surface.ai,dark:r.COLORS.surface.ai,circle:r.COLORS.surface.ai}}};exports.generateBorder=r=>e[r].border,exports.getBackgroundColor=(r,t)=>e[t].backgroundColor[r],exports.getPadding=r=>"regular"===r?"4px 8px":"2px 6px",exports.getTagIconColor=(r,t)=>e[t].iconColor[r],exports.getTextColor=(r,t)=>e[t].textColor[r];
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import*as a from"react";var l;function r(){return r=Object.assign?Object.assign.bind():function(a){for(var l=1;l<arguments.length;l++){var r=arguments[l];for(var t in r)Object.prototype.hasOwnProperty.call(r,t)&&(a[t]=r[t])}return a},r.apply(this,arguments)}var t=t=>a.createElement("svg",r({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 16"},t),l||(l=a.createElement("path",{fill:"currentColor",d:"M11.216 1.025a.133.133 0 0 1 .235 0l.743 1.392a.134.134 0 0 0 .055.055l1.392.743a.133.133 0 0 1 0 .235l-1.392.743a.134.134 0 0 0-.055.054L11.45 5.64a.133.133 0 0 1-.235 0l-.742-1.393a.133.133 0 0 0-.055-.054L9.027 3.45a.133.133 0 0 1 0-.235l1.392-.743a.133.133 0 0 0 .055-.055l.742-1.392Zm-4.124 5.16a.133.133 0 0 0 .055.055l3.077 1.641a.133.133 0 0 1 0 .236l-3.077 1.64a.133.133 0 0 0-.055.056l-1.64 3.077a.133.133 0 0 1-.236 0l-1.64-3.077a.133.133 0 0 0-.056-.055L.443 8.117a.133.133 0 0 1 0-.236l3.077-1.64a.133.133 0 0 0 .055-.055l1.641-3.077a.133.133 0 0 1 .235 0l1.641 3.077Zm.299 1.932a.133.133 0 0 0 0-.236l-1.23-.655a.133.133 0 0 1-.054-.055l-.656-1.23a.133.133 0 0 0-.235 0l-.655 1.23a.133.133 0 0 1-.055.055l-1.23.655a.133.133 0 0 0 0 .236l1.23.655a.133.133 0 0 1 .055.055l.655 1.23c.05.093.185.093.235 0l.656-1.23a.133.133 0 0 1 .055-.055l1.229-.655Zm5.756 2.79a.134.134 0 0 1-.055-.055l-.974-1.827a.133.133 0 0 0-.235 0l-.975 1.827a.133.133 0 0 1-.054.055l-1.827.975a.133.133 0 0 0 0 .235l1.827.974a.132.132 0 0 1 .054.055l.975 1.827c.05.094.185.094.235 0l.974-1.827a.133.133 0 0 1 .055-.055l1.827-.974a.133.133 0 0 0 0-.236l-1.827-.974Z"})));export{t as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{jsxs as e,jsx as i,Fragment as n}from"react/jsx-runtime";import o from"../../assets/icons/Bik_logo.svg.js";import{useState as t,useEffect as l,Fragment as d}from"react";import{COLORS as s}from"../../constants/Theme.js";import{NavigationHyperlink as r}from"../navigation-hyperlink/NavigationHyperlink.js";import{SidebarPopup as a}from"./SidebarPopup.js";import{SideBarContainer as u,SibeBarMenuItem as c}from"./SidebarStyles.js";import{SimpleSidebar as v}from"./SimpleSidebar.js";const m=s=>{const{logoSvg:m,allMenuList:h,activeMainMenu:g,activeSubMenu:y,router:k,onClickingMainMenu:b,onClickingSubMenu:w,onClickingAccessUpgradePanel:
|
|
1
|
+
import{jsxs as e,jsx as i,Fragment as n}from"react/jsx-runtime";import o from"../../assets/icons/Bik_logo.svg.js";import{useState as t,useEffect as l,Fragment as d}from"react";import{COLORS as s}from"../../constants/Theme.js";import{NavigationHyperlink as r}from"../navigation-hyperlink/NavigationHyperlink.js";import{SidebarPopup as a}from"./SidebarPopup.js";import{SideBarContainer as u,SibeBarMenuItem as c}from"./SidebarStyles.js";import{SimpleSidebar as v}from"./SimpleSidebar.js";const m=s=>{const{logoSvg:m,allMenuList:h,activeMainMenu:g,activeSubMenu:y,router:k,onClickingMainMenu:b,onClickingSubMenu:w,onClickingAccessUpgradePanel:M,onClickingPopupMenuItem:S,popupMinHeight:j,isNewSidebar:N}=s,[f,C]=t(g),[L,O]=t(),[I,B]=t(y),[E,H]=t(!1),[P,_]=t(),[x,A]=t(),[$,U]=t();l((()=>{C(g)}),[g]),l((()=>{B(y)}),[y]);const R=e=>{var i,n;if(O(void 0),_(void 0),"popup"==(null==e?void 0:e.layout)){const i=T();i&&A(i),_(e)}else{const o=document.getElementById((null===(n=null===(i=e.displayName)||void 0===i?void 0:i.split(" "))||void 0===n?void 0:n.join(""))||e.key.toString());if(o){const e=o.getBoundingClientRect().top;U(e)}O(e)}},z=(n,o)=>{var t,l,d,s,r,a;return e("div",Object.assign({id:(null===(l=null===(t=n.displayName)||void 0===t?void 0:t.split(" "))||void 0===l?void 0:l.join(""))||n.key.toString(),className:"main--sidebar",onClick:()=>(e=>{var i;"popup"!==(null==e?void 0:e.layout)&&(_(void 0),O(void 0),H(!0),C(e),!e.path&&b(e),(null===(i=null==e?void 0:e.children)||void 0===i?void 0:i.length)?B(null==e?void 0:e.children[0]):B({}),O(void 0),setTimeout((()=>{H(!1)}),1e3))})(n),onMouseEnter:()=>{!E&&R(n)},onMouseOver:()=>{!E&&R(n)},onMouseLeave:()=>{var e;(null===(e=null==n?void 0:n.children)||void 0===e?void 0:e.length)||(O(void 0),_(void 0))},onFocus:()=>{console.log(";")},"aria-hidden":"true"},{children:[n.isNew&&i("div",Object.assign({className:"new-tag"},{children:" NEW"})),e("div",Object.assign({id:(null===(s=null===(d=n.displayName)||void 0===d?void 0:d.split(" "))||void 0===s?void 0:s.join(""))+"_sub"||n.key.toString()+"_sub",className:`sidebar-menu-item ${(null==f?void 0:f.key)==n.key?" main-menu-active-class":""} ${n.isLastSticky?"sticky-menu-int":""} ${n.is2ndLastSticky?"sticky-menu":""}\n\t\t\t\t\t${n.key==(null==L?void 0:L.key)?"sidebar-menu-item-hover":""}\`}\n\t\t\t\t\t${n.isNew?"new-menu-item":""}`},{children:[i(p,{icon:n.icon,isActive:n.key==(null==f?void 0:f.key),activeStateIcon:null!==(r=n.activeIcon)&&void 0!==r?r:{},hoverStateIcon:null!==(a=n.hoverIcon)&&void 0!==a?a:{},isHovered:n.key==(null==L?void 0:L.key)}),i("div",Object.assign({className:"menu-item-container"},{children:i("p",Object.assign({className:"menu-item-text "+((null==n?void 0:n.key)===(null==f?void 0:f.key)?"active-menu-item-text":"")},{children:n.displayName}))}))]}),o)]}),o)};l((()=>{const e=()=>{const e=T();e&&A(e),F()};return window.addEventListener("resize",e),()=>{window.removeEventListener("resize",e)}}),[]);const F=()=>{const e=document.getElementById("_sub-menu"),i=null==e?void 0:e.getBoundingClientRect().height;i&&U(window.innerHeight-i)},T=()=>{var e,i;if(P){const n=(null===(i=null===(e=P.displayName)||void 0===e?void 0:e.split(" "))||void 0===i?void 0:i.join(""))+"_sub"||P.key.toString()+"_sub",o=document.getElementById(n);if(o){const e=o.getBoundingClientRect();let i=e.top;const n=null!=j?j:320;return e.bottom+n>window.innerHeight&&(i-=e.bottom+n-window.innerHeight),i}return null}};return e(u,Object.assign({onMouseLeave:()=>{O(void 0)}},{children:[i("div",Object.assign({className:"bik-header-logo",onClick:()=>{},onKeyDown:()=>{},"aria-hidden":"true"},{children:m||i(o,{})})),i(c,{children:null==h?void 0:h.map(((o,t)=>{var l,s;return e(d,{children:[o.path?i(r,Object.assign({href:o.path,router:k},{children:z(o,t)})):z(o,t),e(n,{children:["popup"===o.layout&&(null===(l=null==P?void 0:P.children)||void 0===l?void 0:l.length)&&i(a,{top:null!=x?x:void 0,menuList:null==P?void 0:P.children,onClickingPopupMenu:e=>{S&&S(e),_(void 0)},onMouseLeaveOnMenu:()=>_(void 0)}),(null===(s=null==L?void 0:L.children)||void 0===s?void 0:s.length)&&i(v,{menuList:null==L?void 0:L.children,activeMenu:I,onMouseLeaveOnMenu:()=>O(void 0),left:N?92:88,postion:"fixed",header:L.displayName,theme:"brand",router:k,showAccessUpgradePanel:L.showAccessUpgradePanel,onMenuClick:(e,i)=>{B(e),C(L),O(void 0),_(void 0),i&&w(e)},onUpgrade:M,top:N&&$||0,isNewSidebar:N})]})]},t)}))})]}))},p=e=>{const{icon:o,isActive:t,activeStateIcon:l,hoverStateIcon:d,isHovered:r}=e,a=o,u=d;return i(n,{children:t?i(l,{width:20,height:20}):i(r?u:a,{width:20,height:20,color:s.surface.standard})})};export{m as BikSidebar};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{jsx as
|
|
1
|
+
import{jsx as i,jsxs as e}from"react/jsx-runtime";import n from"../../assets/icons/bik_ai_stars_icon.svg.js";import r from"react";import{BodyCaption as a}from"../TypographyStyle.js";import{ValidTagTypeMap as t}from"./model.js";import{Tag as s}from"./Tag.styled.js";import{getTagIconColor as c}from"./themes.js";const o=o=>{let{tagText:l,LeadingIcon:g,TrailingIcon:d,onLeadingIconClicked:m,leadingIconId:p,trailingIconId:j,onTrailingIconClicked:b,theme:h="light",type:u="neutral",variant:y="regular",version:O,cursor:f}=o;var v;let I=l,k=h,T=u;t[y][u]||(T="neutral"),"circle"===y&&(k="dark","number"==typeof I&&I>99&&(I="99+"));const w={height:16,width:16,color:c(h,T),style:{display:"block"}},N=()=>"ai"!==u||g?g:n;return i(s,Object.assign({cursor:f,theme:k,type:u,variant:y,version:O},{children:e("div",Object.assign({className:"container"},{children:[N()&&i("button",Object.assign({className:"icon-leading",onClick:m,id:`${p}-wrapper`||"leading-icon-wrapper"},{children:r.createElement(null!==(v=N())&&void 0!==v?v:"",Object.assign(Object.assign({},w),{id:p||"leading-icon"}))})),i(a,Object.assign({className:"text"},{children:I})),d&&i("button",Object.assign({className:"icon-trailing",onClick:b,id:`${j}-wrapper`||"trailing-icon-wrapper"},{children:r.createElement(d,Object.assign(Object.assign({},w),{id:j||"trailing-icon"}))}))]}))}))};o.displayName="Tag";export{o as Tag};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import c from"@emotion/styled/base";import{getPadding as l,getBackgroundColor as b,generateBorder as d,getTextColor as t}from"./themes.js";const e=c("div","production"===process.env.NODE_ENV?{target:"e930jd90"}:{target:"e930jd90",label:"Tag"})("cursor:",(c=>{var l;return null!==(l=c.cursor)&&void 0!==l?l:"default"}),";",(c=>"regular"===c.variant?"display: block;\n\t\t min-height: 26px;\n\t\t":"min-height: 20px;")," .container{display:flex;align-items:center;gap:6px;padding:",(c=>l(c.variant)),";background
|
|
1
|
+
import c from"@emotion/styled/base";import{getPadding as l,getBackgroundColor as b,generateBorder as d,getTextColor as t}from"./themes.js";const e=c("div","production"===process.env.NODE_ENV?{target:"e930jd90"}:{target:"e930jd90",label:"Tag"})("cursor:",(c=>{var l;return null!==(l=c.cursor)&&void 0!==l?l:"default"}),";",(c=>"regular"===c.variant?"display: block;\n\t\t min-height: 26px;\n\t\t":"min-height: 20px;")," .container{display:flex;align-items:center;gap:6px;padding:",(c=>l(c.variant)),";background:",(c=>b(c.theme,c.type)),";border-radius:",(c=>"regular"===c.variant?"4px":"12px"),";",(c=>"light"===c.theme&&`border: ${"2.0"===c.version?.5:1}px solid ${d(c.type)};`)," .text{color:",(c=>t(c.theme,c.type)),";}.icon-trailing{all:unset;display:flex;}.icon-leading{all:unset;display:flex;}}"+("production"===process.env.NODE_ENV?"":"/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIlRhZy5zdHlsZWQudHN4Il0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUU4QiIsImZpbGUiOiJUYWcuc3R5bGVkLnRzeCIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCBzdHlsZWQgZnJvbSAnQGVtb3Rpb24vc3R5bGVkJztcclxuaW1wb3J0IHsgZ2VuZXJhdGVCb3JkZXIsIGdldEJhY2tncm91bmRDb2xvciwgZ2V0UGFkZGluZywgZ2V0VGV4dENvbG9yLCB9IGZyb20gJy4vdGhlbWVzJztcclxuZXhwb3J0IGNvbnN0IFRhZyA9IHN0eWxlZC5kaXYgYFxuXHRjdXJzb3I6ICR7KHByb3BzKSA9PiB7IHZhciBfYTsgcmV0dXJuIChfYSA9IHByb3BzLmN1cnNvcikgIT09IG51bGwgJiYgX2EgIT09IHZvaWQgMCA/IF9hIDogJ2RlZmF1bHQnOyB9fTtcblx0JHsocHJvcHMpID0+IHByb3BzLnZhcmlhbnQgPT09ICdyZWd1bGFyJ1xyXG4gICAgPyBgZGlzcGxheTogYmxvY2s7XG5cdFx0ICAgICBtaW4taGVpZ2h0OiAyNnB4O1xuXHRcdGBcclxuICAgIDogYG1pbi1oZWlnaHQ6IDIwcHg7YH1cblx0LmNvbnRhaW5lciB7XG5cdFx0ZGlzcGxheTogZmxleDtcblx0XHRhbGlnbi1pdGVtczogY2VudGVyO1xuXHRcdGdhcDogNnB4O1xuXHRcdHBhZGRpbmc6ICR7KHByb3BzKSA9PiBnZXRQYWRkaW5nKHByb3BzLnZhcmlhbnQpfTtcblxuXHRcdGJhY2tncm91bmQ6ICR7KHByb3BzKSA9PiBnZXRCYWNrZ3JvdW5kQ29sb3IocHJvcHMudGhlbWUsIHByb3BzLnR5cGUpfTtcblxuXHRcdGJvcmRlci1yYWRpdXM6ICR7KHByb3BzKSA9PiAocHJvcHMudmFyaWFudCA9PT0gJ3JlZ3VsYXInID8gJzRweCcgOiAnMTJweCcpfTtcblxuXHRcdCR7KHByb3BzKSA9PiBwcm9wcy50aGVtZSA9PT0gJ2xpZ2h0JyAmJlxyXG4gICAgYGJvcmRlcjogJHtwcm9wcy52ZXJzaW9uID09PSAnMi4wJyA/IDAuNSA6IDF9cHggc29saWQgJHtnZW5lcmF0ZUJvcmRlcihwcm9wcy50eXBlKX07YH1cblxuXHRcdC50ZXh0IHtcblx0XHRcdGNvbG9yOiAkeyhwcm9wcykgPT4gZ2V0VGV4dENvbG9yKHByb3BzLnRoZW1lLCBwcm9wcy50eXBlKX07XG5cdFx0fVxuXG5cdFx0Lmljb24tdHJhaWxpbmcge1xuXHRcdFx0YWxsOiB1bnNldDtcblx0XHRcdGRpc3BsYXk6IGZsZXg7XG5cdFx0fVxuXG5cdFx0Lmljb24tbGVhZGluZyB7XG5cdFx0XHRhbGw6IHVuc2V0O1xuXHRcdFx0ZGlzcGxheTogZmxleDtcblx0XHR9XG5cdH1cbmA7XHJcbi8vIyBzb3VyY2VNYXBwaW5nVVJMPVRhZy5zdHlsZWQuanMubWFwIl19 */"));export{e as Tag};
|
|
@@ -2,7 +2,7 @@ import React from 'react';
|
|
|
2
2
|
import { MouseEventHandler } from 'react';
|
|
3
3
|
export type TagTheme = 'light' | 'dark';
|
|
4
4
|
export type TagVariant = 'regular' | 'circle';
|
|
5
|
-
export type TagType = 'negative' | 'warning' | 'positive' | 'neutral' | 'white' | 'purple' | 'blue' | 'grey';
|
|
5
|
+
export type TagType = 'negative' | 'warning' | 'positive' | 'neutral' | 'white' | 'purple' | 'blue' | 'grey' | 'ai';
|
|
6
6
|
export declare const ValidTagTypeMap: {
|
|
7
7
|
regular: {
|
|
8
8
|
negative: boolean;
|
|
@@ -12,6 +12,7 @@ export declare const ValidTagTypeMap: {
|
|
|
12
12
|
white: boolean;
|
|
13
13
|
purple: boolean;
|
|
14
14
|
blue: boolean;
|
|
15
|
+
ai: boolean;
|
|
15
16
|
};
|
|
16
17
|
circle: {
|
|
17
18
|
negative: boolean;
|
|
@@ -20,6 +21,7 @@ export declare const ValidTagTypeMap: {
|
|
|
20
21
|
neutral: boolean;
|
|
21
22
|
blue: boolean;
|
|
22
23
|
grey: boolean;
|
|
24
|
+
ai: boolean;
|
|
23
25
|
};
|
|
24
26
|
};
|
|
25
27
|
export interface TagProps extends React.BaseHTMLAttributes<HTMLDivElement> {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const e={regular:{negative:!0,warning:!0,positive:!0,neutral:!0,white:!0,purple:!0,blue:!0},circle:{negative:!0,warning:!0,positive:!0,neutral:!0,blue:!0,grey:!0}};export{e as ValidTagTypeMap};
|
|
1
|
+
const e={regular:{negative:!0,warning:!0,positive:!0,neutral:!0,white:!0,purple:!0,blue:!0,ai:!0},circle:{negative:!0,warning:!0,positive:!0,neutral:!0,blue:!0,grey:!0,ai:!0}};export{e as ValidTagTypeMap};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{COLORS as r}from"../../constants/Theme.js";const n={blue:{iconColor:{light:r.content.blue,dark:r.content.primaryInverse},textColor:{light:r.content.blue,dark:r.content.primaryInverse},border:r.stroke.blue.lightAlt,backgroundColor:{light:r.background.blue.light,dark:r.content.blue,circle:r.content.blue}},purple:{iconColor:{light:r.background.inverseLight,dark:r.content.primaryInverse},textColor:{light:r.background.inverseLight,dark:r.content.primaryInverse},border:r.stroke.brandLightAlt,backgroundColor:{light:r.background.brandLight,dark:r.background.inverse,circle:r.background.inverse}},negative:{iconColor:{light:r.content.negative,dark:r.content.primaryInverse},textColor:{light:r.content.negative,dark:r.content.primaryInverse},border:r.stroke.negative.lightAlt,backgroundColor:{light:r.background.negative.light,dark:r.background.negative.vibrant,circle:r.background.negative.vibrant}},positive:{iconColor:{light:r.content.positive,dark:r.content.primaryInverse},textColor:{light:r.content.positive,dark:r.content.primaryInverse},border:r.stroke.positive.lightAlt,backgroundColor:{light:r.background.positive.light,dark:r.background.positive.vibrant,circle:r.background.positive.vibrant}},warning:{iconColor:{light:r.content.warning,dark:r.content.primary},textColor:{light:r.content.warning,dark:r.content.primary},border:r.stroke.warning.lightAlt,backgroundColor:{light:r.background.warning.light,dark:r.background.warning.vibrant,circle:r.background.warning.vibrant}},neutral:{iconColor:{light:r.content.secondary,dark:r.content.primaryInverse},textColor:{light:r.content.secondary,dark:r.content.primaryInverse},border:r.stroke.primary,backgroundColor:{light:r.surface.subdued,dark:r.background.inverse,circle:r.background.inverseLight}},white:{iconColor:{light:r.content.secondary,dark:r.content.primaryInverse},textColor:{light:r.content.secondary,dark:r.content.primaryInverse},border:r.stroke.primary,backgroundColor:{light:r.surface.standard,dark:r.background.inverse,circle:r.background.inverseLight}},grey:{iconColor:{light:r.content.secondary,dark:r.content.primaryInverse},textColor:{light:r.content.secondary,dark:r.content.primaryInverse},border:r.stroke.primary,backgroundColor:{light:r.surface.subdued,dark:r.content.secondary,circle:r.content.secondary}}},
|
|
1
|
+
import{COLORS as r}from"../../constants/Theme.js";const n={blue:{iconColor:{light:r.content.blue,dark:r.content.primaryInverse},textColor:{light:r.content.blue,dark:r.content.primaryInverse},border:r.stroke.blue.lightAlt,backgroundColor:{light:r.background.blue.light,dark:r.content.blue,circle:r.content.blue}},purple:{iconColor:{light:r.background.inverseLight,dark:r.content.primaryInverse},textColor:{light:r.background.inverseLight,dark:r.content.primaryInverse},border:r.stroke.brandLightAlt,backgroundColor:{light:r.background.brandLight,dark:r.background.inverse,circle:r.background.inverse}},negative:{iconColor:{light:r.content.negative,dark:r.content.primaryInverse},textColor:{light:r.content.negative,dark:r.content.primaryInverse},border:r.stroke.negative.lightAlt,backgroundColor:{light:r.background.negative.light,dark:r.background.negative.vibrant,circle:r.background.negative.vibrant}},positive:{iconColor:{light:r.content.positive,dark:r.content.primaryInverse},textColor:{light:r.content.positive,dark:r.content.primaryInverse},border:r.stroke.positive.lightAlt,backgroundColor:{light:r.background.positive.light,dark:r.background.positive.vibrant,circle:r.background.positive.vibrant}},warning:{iconColor:{light:r.content.warning,dark:r.content.primary},textColor:{light:r.content.warning,dark:r.content.primary},border:r.stroke.warning.lightAlt,backgroundColor:{light:r.background.warning.light,dark:r.background.warning.vibrant,circle:r.background.warning.vibrant}},neutral:{iconColor:{light:r.content.secondary,dark:r.content.primaryInverse},textColor:{light:r.content.secondary,dark:r.content.primaryInverse},border:r.stroke.primary,backgroundColor:{light:r.surface.subdued,dark:r.background.inverse,circle:r.background.inverseLight}},white:{iconColor:{light:r.content.secondary,dark:r.content.primaryInverse},textColor:{light:r.content.secondary,dark:r.content.primaryInverse},border:r.stroke.primary,backgroundColor:{light:r.surface.standard,dark:r.background.inverse,circle:r.background.inverseLight}},grey:{iconColor:{light:r.content.secondary,dark:r.content.primaryInverse},textColor:{light:r.content.secondary,dark:r.content.primaryInverse},border:r.stroke.primary,backgroundColor:{light:r.surface.subdued,dark:r.content.secondary,circle:r.content.secondary}},ai:{iconColor:{light:r.content.primaryInverse,dark:r.content.primaryInverse},textColor:{light:r.content.primaryInverse,dark:r.content.primaryInverse},border:"none",backgroundColor:{light:r.surface.ai,dark:r.surface.ai,circle:r.surface.ai}}},e=(r,e)=>n[e].iconColor[r],t=(r,e)=>n[e].textColor[r],o=r=>n[r].border,i=(r,e)=>n[e].backgroundColor[r],a=r=>"regular"===r?"4px 8px":"2px 6px";export{o as generateBorder,i as getBackgroundColor,a as getPadding,e as getTagIconColor,t as getTextColor};
|