@bikdotai/bik-component-library 0.0.243 → 0.0.244

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.
@@ -2,7 +2,7 @@
2
2
  export declare const KeywordsInput: (props: {
3
3
  keywords: string[];
4
4
  onDeleteKeyword: (name: string) => void;
5
- onSelectKeyword?: ((kwds: string[]) => void) | undefined;
5
+ onSelectKeyword?: ((kwd: string) => void) | undefined;
6
6
  placeHolder?: string | undefined;
7
7
  error?: boolean | undefined;
8
8
  errorMessage?: string | undefined;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),r=require("../../assets/icons/cross.svg.js"),t=require("react"),i=require("../input/Input.js"),s=require("../tag/Tag.js");exports.KeywordsInput=o=>{var n;const[a,l]=t.useState(""),{keywords:d,onDeleteKeyword:c,errorMessage:u,onSelectKeyword:p,error:g,hint:x,width:w}=o;return e.jsxs("div",Object.assign({style:{marginTop:12}},{children:[e.jsx(i.Input,{width:w,onChangeText:function(e,r){!r||"keydown"!==(null==r?void 0:r.type)||13!==r.which&&13!==r.keyCode?l(e):e.trim()&&(l(""),p&&p([...d,e.trim()]))},value:a,hintText:x,placeholder:null!==(n=o.placeHolder)&&void 0!==n?n:"Ex. Hello",errorMessage:g?u||"Please ENTER to add keyword":""}),e.jsx("div",Object.assign({style:{display:"flex",flexDirection:"row",gap:"8px",marginTop:12,flexWrap:"wrap",width:w}},{children:d.map(((t,i)=>e.jsx(s.Tag,{tagText:t,TrailingIcon:r.default,onTrailingIconClicked:()=>c(t)},t+i)))}))]}))};
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),r=require("../../assets/icons/cross.svg.js"),t=require("react"),i=require("../input/Input.js"),s=require("../tag/Tag.js");exports.KeywordsInput=o=>{var n;const[a,l]=t.useState(""),{keywords:d,onDeleteKeyword:c,errorMessage:u,onSelectKeyword:p,error:g,hint:x,width:w}=o;return e.jsxs("div",Object.assign({style:{marginTop:12}},{children:[e.jsx(i.Input,{width:w,onChangeText:function(e,r){!r||"keydown"!==(null==r?void 0:r.type)||13!==r.which&&13!==r.keyCode?l(e):e.trim()&&(l(""),p&&p(e.trim()))},value:a,hintText:x,placeholder:null!==(n=o.placeHolder)&&void 0!==n?n:"Ex. Hello",errorMessage:g?u||"Please ENTER to add keyword":""}),e.jsx("div",Object.assign({style:{display:"flex",flexDirection:"row",gap:"8px",marginTop:12,flexWrap:"wrap",width:w}},{children:d.map(((t,i)=>e.jsx(s.Tag,{tagText:t,TrailingIcon:r.default,onTrailingIconClicked:()=>c(t)},t+i)))}))]}))};
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var t=require("react/jsx-runtime"),e=require("@tippyjs/react"),n=require("react"),r=require("./TooltipInternal.js"),o=require("../../constants/Theme.js");function i(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}var a=i(e),l=i(n);const p=`\n\t.tippy-content {\n\t\tpadding: 0px;\n\t}\n\t.tippy-arrow {\n\t\tcolor: ${t=>o.COLORS.content.primary};\n\t}\n\t.overflow-wrap-tippy {\n\t\toverflow-wrap: anywhere;\n\t}\n`;exports.Tooltip=e=>l.default.isValidElement(e.children)?t.jsxs(t.Fragment,{children:[t.jsx("style",{children:p}),t.jsx(a.default,Object.assign({appendTo:document.body,className:"overflow-wrap-tippy",placement:e.placement||"right",maxWidth:e.width,animation:"fade",arrow:!0,interactive:!0,content:e.tooltipContent?e.tooltipContent:t.jsx(r.default,{title:e.title,body:e.body,buttonProps:e.buttonProps})},{children:e.children}))]}):null;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var t=require("react/jsx-runtime"),e=require("@tippyjs/react"),n=require("react"),r=require("./TooltipInternal.js"),o=require("../../constants/Theme.js");function i(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}var a=i(e),l=i(n);const p=`\n\t.tippy-content {\n\t\tpadding: 0px;\n\t}\n\t.tippy-arrow {\n\t\tcolor: ${t=>o.COLORS.content.primary};\n\t}\n\t.overflow-wrap-tippy {\n\t\toverflow-wrap: anywhere;\n\t}\n`;exports.Tooltip=e=>l.default.isValidElement(e.children)?t.jsxs(t.Fragment,{children:[t.jsx("style",{children:p}),t.jsx(a.default,Object.assign({appendTo:document.body,className:"overflow-wrap-tippy",placement:e.placement||"right",maxWidth:e.width,animation:"fade",arrow:!0,interactive:!0,delay:e.delay,content:e.tooltipContent?e.tooltipContent:t.jsx(r.default,{title:e.title,body:e.body,buttonProps:e.buttonProps})},{children:e.children}))]}):null;
@@ -4,6 +4,7 @@ export interface TooltipInternalProps {
4
4
  title?: string;
5
5
  body: string;
6
6
  buttonProps?: ButtonProps;
7
+ delay?: number;
7
8
  }
8
9
  type Props = TooltipInternalProps;
9
10
  declare const TooltipInternal: FunctionComponent<Props>;
@@ -2,7 +2,7 @@
2
2
  export declare const KeywordsInput: (props: {
3
3
  keywords: string[];
4
4
  onDeleteKeyword: (name: string) => void;
5
- onSelectKeyword?: ((kwds: string[]) => void) | undefined;
5
+ onSelectKeyword?: ((kwd: string) => void) | undefined;
6
6
  placeHolder?: string | undefined;
7
7
  error?: boolean | undefined;
8
8
  errorMessage?: string | undefined;
@@ -1 +1 @@
1
- import{jsxs as e,jsx as r}from"react/jsx-runtime";import o from"../../assets/icons/cross.svg.js";import{useState as t}from"react";import{Input as i}from"../input/Input.js";import{Tag as n}from"../tag/Tag.js";const a=a=>{var s;const[l,d]=t(""),{keywords:c,onDeleteKeyword:p,errorMessage:m,onSelectKeyword:g,error:h,hint:w,width:x}=a;return e("div",Object.assign({style:{marginTop:12}},{children:[r(i,{width:x,onChangeText:function(e,r){!r||"keydown"!==(null==r?void 0:r.type)||13!==r.which&&13!==r.keyCode?d(e):e.trim()&&(d(""),g&&g([...c,e.trim()]))},value:l,hintText:w,placeholder:null!==(s=a.placeHolder)&&void 0!==s?s:"Ex. Hello",errorMessage:h?m||"Please ENTER to add keyword":""}),r("div",Object.assign({style:{display:"flex",flexDirection:"row",gap:"8px",marginTop:12,flexWrap:"wrap",width:x}},{children:c.map(((e,t)=>r(n,{tagText:e,TrailingIcon:o,onTrailingIconClicked:()=>p(e)},e+t)))}))]}))};export{a as KeywordsInput};
1
+ import{jsxs as e,jsx as r}from"react/jsx-runtime";import o from"../../assets/icons/cross.svg.js";import{useState as t}from"react";import{Input as i}from"../input/Input.js";import{Tag as n}from"../tag/Tag.js";const a=a=>{var s;const[l,d]=t(""),{keywords:c,onDeleteKeyword:p,errorMessage:m,onSelectKeyword:g,error:h,hint:w,width:x}=a;return e("div",Object.assign({style:{marginTop:12}},{children:[r(i,{width:x,onChangeText:function(e,r){!r||"keydown"!==(null==r?void 0:r.type)||13!==r.which&&13!==r.keyCode?d(e):e.trim()&&(d(""),g&&g(e.trim()))},value:l,hintText:w,placeholder:null!==(s=a.placeHolder)&&void 0!==s?s:"Ex. Hello",errorMessage:h?m||"Please ENTER to add keyword":""}),r("div",Object.assign({style:{display:"flex",flexDirection:"row",gap:"8px",marginTop:12,flexWrap:"wrap",width:x}},{children:c.map(((e,t)=>r(n,{tagText:e,TrailingIcon:o,onTrailingIconClicked:()=>p(e)},e+t)))}))]}))};export{a as KeywordsInput};
@@ -1 +1 @@
1
- import{jsxs as t,Fragment as n,jsx as o}from"react/jsx-runtime";import e from"@tippyjs/react";import r from"react";import i from"./TooltipInternal.js";import{COLORS as p}from"../../constants/Theme.js";const a=`\n\t.tippy-content {\n\t\tpadding: 0px;\n\t}\n\t.tippy-arrow {\n\t\tcolor: ${t=>p.content.primary};\n\t}\n\t.overflow-wrap-tippy {\n\t\toverflow-wrap: anywhere;\n\t}\n`,l=p=>r.isValidElement(p.children)?t(n,{children:[o("style",{children:a}),o(e,Object.assign({appendTo:document.body,className:"overflow-wrap-tippy",placement:p.placement||"right",maxWidth:p.width,animation:"fade",arrow:!0,interactive:!0,content:p.tooltipContent?p.tooltipContent:o(i,{title:p.title,body:p.body,buttonProps:p.buttonProps})},{children:p.children}))]}):null;export{l as Tooltip};
1
+ import{jsxs as t,Fragment as n,jsx as o}from"react/jsx-runtime";import e from"@tippyjs/react";import r from"react";import i from"./TooltipInternal.js";import{COLORS as p}from"../../constants/Theme.js";const a=`\n\t.tippy-content {\n\t\tpadding: 0px;\n\t}\n\t.tippy-arrow {\n\t\tcolor: ${t=>p.content.primary};\n\t}\n\t.overflow-wrap-tippy {\n\t\toverflow-wrap: anywhere;\n\t}\n`,l=p=>r.isValidElement(p.children)?t(n,{children:[o("style",{children:a}),o(e,Object.assign({appendTo:document.body,className:"overflow-wrap-tippy",placement:p.placement||"right",maxWidth:p.width,animation:"fade",arrow:!0,interactive:!0,delay:p.delay,content:p.tooltipContent?p.tooltipContent:o(i,{title:p.title,body:p.body,buttonProps:p.buttonProps})},{children:p.children}))]}):null;export{l as Tooltip};
@@ -4,6 +4,7 @@ export interface TooltipInternalProps {
4
4
  title?: string;
5
5
  body: string;
6
6
  buttonProps?: ButtonProps;
7
+ delay?: number;
7
8
  }
8
9
  type Props = TooltipInternalProps;
9
10
  declare const TooltipInternal: FunctionComponent<Props>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bikdotai/bik-component-library",
3
- "version": "0.0.243",
3
+ "version": "0.0.244",
4
4
  "description": "Bik Component Library",
5
5
  "repository": {
6
6
  "type": "git",