1mpacto-react-ui 2.0.26 → 2.0.28
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/assets/_mixins.scss +6 -1
- package/dist/assets/_typography.scss +19 -15
- package/dist/assets/core.css +1 -1
- package/dist/assets/style.css +1 -1
- package/dist/components/Alert/index.cjs +1 -1
- package/dist/components/Alert/index.mjs +55 -51
- package/dist/components/Alert/style.module.scss.cjs +1 -1
- package/dist/components/Alert/style.module.scss.mjs +12 -11
- package/dist/components/Badges/Badges.config.cjs +1 -1
- package/dist/components/Badges/Badges.config.mjs +18 -3
- package/dist/components/Badges/style.module.scss.cjs +1 -1
- package/dist/components/Badges/style.module.scss.mjs +46 -35
- package/dist/components/Breadcrumbs/Breadcrumbs.cjs +3 -3
- package/dist/components/Breadcrumbs/Breadcrumbs.config.cjs +1 -1
- package/dist/components/Breadcrumbs/Breadcrumbs.config.mjs +4 -3
- package/dist/components/Breadcrumbs/Breadcrumbs.mjs +45 -43
- package/dist/components/Breadcrumbs/style.module.scss.cjs +1 -1
- package/dist/components/Breadcrumbs/style.module.scss.mjs +12 -9
- package/dist/components/Button/Button.config.cjs +1 -1
- package/dist/components/Button/Button.config.mjs +10 -2
- package/dist/components/Button/style.module.scss.cjs +1 -1
- package/dist/components/Button/style.module.scss.mjs +64 -60
- package/dist/components/ButtonIcon/ButtonIcon.config.cjs +1 -1
- package/dist/components/ButtonIcon/ButtonIcon.config.mjs +58 -47
- package/dist/components/ButtonIcon/style.module.scss.cjs +1 -1
- package/dist/components/ButtonIcon/style.module.scss.mjs +55 -48
- package/dist/components/Input/InputInnerLabel.module.scss.cjs +1 -1
- package/dist/components/Input/InputInnerLabel.module.scss.mjs +19 -19
- package/dist/components/Modal/ModalDialog.cjs +11 -1
- package/dist/components/Modal/ModalDialog.config.cjs +1 -1
- package/dist/components/Modal/ModalDialog.config.mjs +18 -7
- package/dist/components/Modal/ModalDialog.mjs +59 -32
- package/dist/components/Modal/style.module.scss.cjs +1 -1
- package/dist/components/Modal/style.module.scss.mjs +17 -11
- package/dist/components/Pagination/Pagination.cjs +2 -2
- package/dist/components/Pagination/Pagination.config.cjs +1 -1
- package/dist/components/Pagination/Pagination.config.mjs +4 -3
- package/dist/components/Pagination/Pagination.mjs +90 -90
- package/dist/components/Pagination/style.module.scss.cjs +1 -1
- package/dist/components/Pagination/style.module.scss.mjs +18 -16
- package/dist/components/Popover/Popover.cjs +1 -1
- package/dist/components/Popover/Popover.config.cjs +1 -0
- package/dist/components/Popover/Popover.config.mjs +11 -0
- package/dist/components/Popover/Popover.mjs +42 -40
- package/dist/components/Popover/style.module.scss.cjs +1 -1
- package/dist/components/Popover/style.module.scss.mjs +8 -4
- package/dist/components/RadioCheckbox/RadioCheckbox.config.cjs +1 -1
- package/dist/components/RadioCheckbox/RadioCheckbox.config.mjs +24 -22
- package/dist/components/RadioCheckbox/RadioCheckbox.module.scss.cjs +1 -1
- package/dist/components/RadioCheckbox/RadioCheckbox.module.scss.mjs +25 -23
- package/dist/components/RadioCheckbox/RadioCheckboxLabel.config.cjs +1 -1
- package/dist/components/RadioCheckbox/RadioCheckboxLabel.config.mjs +5 -4
- package/dist/components/RadioCheckbox/RadioCheckboxLabel.module.scss.cjs +1 -1
- package/dist/components/RadioCheckbox/RadioCheckboxLabel.module.scss.mjs +8 -7
- package/dist/components/SelectDropdownContainer/SelectDropdownContainer.cjs +1 -1
- package/dist/components/SelectDropdownContainer/SelectDropdownContainer.config.cjs +1 -1
- package/dist/components/SelectDropdownContainer/SelectDropdownContainer.config.mjs +19 -10
- package/dist/components/SelectDropdownContainer/SelectDropdownContainer.mjs +95 -80
- package/dist/components/SelectDropdownContainer/styleConfig.cjs +1 -1
- package/dist/components/SelectDropdownContainer/styleConfig.mjs +151 -11
- package/dist/components/Sidebar/Sidebar.module.scss.cjs +1 -1
- package/dist/components/Sidebar/Sidebar.module.scss.mjs +22 -22
- package/dist/components/Sidebar/itemSidebar.module.scss.cjs +1 -1
- package/dist/components/Sidebar/itemSidebar.module.scss.mjs +25 -25
- package/dist/components/Step/StepIndicator.cjs +6 -4
- package/dist/components/Step/StepIndicator.config.cjs +1 -0
- package/dist/components/Step/StepIndicator.config.mjs +12 -0
- package/dist/components/Step/StepIndicator.mjs +31 -26
- package/dist/components/Step/StepIndicator.module.scss.cjs +1 -1
- package/dist/components/Step/StepIndicator.module.scss.mjs +12 -11
- package/dist/components/Switch/Switch.config.cjs +1 -1
- package/dist/components/Switch/Switch.config.mjs +6 -3
- package/dist/components/Switch/style.module.scss.cjs +1 -1
- package/dist/components/Switch/style.module.scss.mjs +18 -15
- package/dist/components/Tabs/Tabs.config.cjs +1 -1
- package/dist/components/Tabs/Tabs.config.mjs +13 -6
- package/dist/components/Tabs/style.module.scss.cjs +1 -1
- package/dist/components/Tabs/style.module.scss.mjs +29 -23
- package/dist/components/Textarea/TextareaFloatingInner.cjs +6 -5
- package/dist/components/Textarea/TextareaFloatingInner.config.cjs +1 -1
- package/dist/components/Textarea/TextareaFloatingInner.config.mjs +6 -2
- package/dist/components/Textarea/TextareaFloatingInner.mjs +38 -36
- package/dist/components/Textarea/TextareaFloatingInner.module.scss.cjs +1 -1
- package/dist/components/Textarea/TextareaFloatingInner.module.scss.mjs +11 -9
- package/dist/components/fin/Chat/BubbleChat.cjs +1 -0
- package/dist/components/fin/Chat/BubbleChat.mjs +20 -0
- package/dist/components/fin/Chat/BubbleChatOption.cjs +1 -0
- package/dist/components/fin/Chat/BubbleChatOption.mjs +70 -0
- package/dist/components/fin/Chat/BubbleChatUser.cjs +1 -0
- package/dist/components/fin/Chat/BubbleChatUser.mjs +15 -0
- package/dist/components/fin/Chat/Icons.cjs +1 -0
- package/dist/components/fin/Chat/Icons.mjs +44 -0
- package/dist/components/fin/Chat/style.module.scss.cjs +1 -0
- package/dist/components/fin/Chat/style.module.scss.mjs +27 -0
- package/dist/config/components/typography.cjs +1 -1
- package/dist/config/components/typography.mjs +40 -6
- package/dist/config/tailwind/typography.cjs +1 -1
- package/dist/config/tailwind/typography.mjs +23 -15
- package/dist/index.cjs +1 -1
- package/dist/index.mjs +86 -80
- package/dist/package.json.cjs +1 -1
- package/dist/package.json.d.ts +1 -1
- package/dist/package.json.mjs +1 -1
- package/dist/src/components/Badges/Badges.config.d.ts +15 -0
- package/dist/src/components/Breadcrumbs/Breadcrumbs.config.d.ts +1 -0
- package/dist/src/components/Button/Button.config.d.ts +8 -0
- package/dist/src/components/ButtonIcon/ButtonIcon.config.d.ts +11 -0
- package/dist/src/components/Modal/ModalDialog.config.d.ts +12 -0
- package/dist/src/components/Modal/ModalDialog.d.ts +1 -1
- package/dist/src/components/Modal/ModalDialog.stories.d.ts +17 -1
- package/dist/src/components/Pagination/Pagination.config.d.ts +1 -0
- package/dist/src/components/Pagination/Pagination.d.ts +1 -1
- package/dist/src/components/Pagination/Pagination.stories.d.ts +14 -1
- package/dist/src/components/Popover/Popover.config.d.ts +8 -0
- package/dist/src/components/RadioCheckbox/RadioCheckbox.config.d.ts +2 -0
- package/dist/src/components/RadioCheckbox/RadioCheckboxLabel.config.d.ts +1 -0
- package/dist/src/components/SelectDropdownContainer/SelectDropdownContainer.config.d.ts +10 -0
- package/dist/src/components/SelectDropdownContainer/styleConfig.d.ts +2 -0
- package/dist/src/components/Step/StepIndicator.config.d.ts +18 -0
- package/dist/src/components/Step/StepIndicator.d.ts +1 -1
- package/dist/src/components/Step/StepIndicator.stories.d.ts +30 -1
- package/dist/src/components/Switch/Switch.config.d.ts +3 -0
- package/dist/src/components/Tabs/Tabs.config.d.ts +7 -1
- package/dist/src/components/Textarea/TextareaFloatingInner.config.d.ts +5 -0
- package/dist/src/components/fin/Chat/BubbleChat.d.ts +3 -0
- package/dist/src/components/fin/Chat/BubbleChatOption.d.ts +3 -0
- package/dist/src/components/fin/Chat/BubbleChatUser.d.ts +3 -0
- package/dist/src/components/fin/Chat/Icons.d.ts +5 -0
- package/dist/src/components/fin/index.d.ts +4 -0
- package/dist/src/components/index.d.ts +2 -1
- package/dist/src/config/components/typography.d.ts +1 -1
- package/dist/src/interfaces/components/Badges/index.d.ts +6 -1
- package/dist/src/interfaces/components/Breadcrumbs/index.d.ts +1 -1
- package/dist/src/interfaces/components/Button/index.d.ts +1 -1
- package/dist/src/interfaces/components/ButtonIcon/index.d.ts +2 -2
- package/dist/src/interfaces/components/Modal/index.d.ts +10 -0
- package/dist/src/interfaces/components/Pagination/index.d.ts +6 -1
- package/dist/src/interfaces/components/Popover/index.d.ts +5 -0
- package/dist/src/interfaces/components/RadioCheckbox/RadioCheckbox.d.ts +1 -1
- package/dist/src/interfaces/components/RadioCheckbox/RadioCheckboxLabel.d.ts +1 -1
- package/dist/src/interfaces/components/SelectDropdownContainer/index.d.ts +7 -1
- package/dist/src/interfaces/components/Step/index.d.ts +13 -2
- package/dist/src/interfaces/components/Switch/index.d.ts +1 -1
- package/dist/src/interfaces/components/Tabs/index.d.ts +2 -2
- package/dist/src/interfaces/components/Textarea/index.d.ts +5 -0
- package/dist/src/interfaces/components/fin/Chat/index.d.ts +39 -0
- package/package.json +1 -1
|
@@ -1,26 +1,28 @@
|
|
|
1
|
-
const
|
|
2
|
-
container:
|
|
3
|
-
"container-input": "_container-
|
|
4
|
-
"input-radio-checkbox-s": "_input-radio-checkbox-
|
|
5
|
-
"input-radio-checkbox-m": "_input-radio-checkbox-
|
|
6
|
-
"input-radio-checkbox-small": "_input-radio-checkbox-
|
|
7
|
-
"input-radio-checkbox-reguler": "_input-radio-checkbox-
|
|
8
|
-
"checked-icon": "_checked-
|
|
9
|
-
"default-disabled-radio": "_default-disabled-
|
|
10
|
-
"default-disabled-checkbox": "_default-disabled-
|
|
11
|
-
"laba-blue-10": "_laba-blue-
|
|
12
|
-
"laba-blue-10-hv_bg_transparent": "_laba-blue-10-
|
|
13
|
-
"blue-700": "_blue-
|
|
14
|
-
"blue-700-hv_bg_transparent": "_blue-700-
|
|
15
|
-
"bill-primary-500": "_bill-primary-
|
|
16
|
-
"bill-primary-600-hv_bg_transparent": "_bill-primary-600-
|
|
17
|
-
"bill-secondary-800-hv_bg_transparent": "_bill-secondary-800-
|
|
18
|
-
|
|
19
|
-
|
|
1
|
+
const _ = "_container_8svpp_1", a = "_label_8svpp_239", p = "_disabled_8svpp_243", e = {
|
|
2
|
+
container: _,
|
|
3
|
+
"container-input": "_container-input_8svpp_1",
|
|
4
|
+
"input-radio-checkbox-s": "_input-radio-checkbox-s_8svpp_1",
|
|
5
|
+
"input-radio-checkbox-m": "_input-radio-checkbox-m_8svpp_1",
|
|
6
|
+
"input-radio-checkbox-small": "_input-radio-checkbox-small_8svpp_1",
|
|
7
|
+
"input-radio-checkbox-reguler": "_input-radio-checkbox-reguler_8svpp_1",
|
|
8
|
+
"checked-icon": "_checked-icon_8svpp_11",
|
|
9
|
+
"default-disabled-radio": "_default-disabled-radio_8svpp_48",
|
|
10
|
+
"default-disabled-checkbox": "_default-disabled-checkbox_8svpp_58",
|
|
11
|
+
"laba-blue-10": "_laba-blue-10_8svpp_66",
|
|
12
|
+
"laba-blue-10-hv_bg_transparent": "_laba-blue-10-hv_bg_transparent_8svpp_78",
|
|
13
|
+
"blue-700": "_blue-700_8svpp_90",
|
|
14
|
+
"blue-700-hv_bg_transparent": "_blue-700-hv_bg_transparent_8svpp_102",
|
|
15
|
+
"bill-primary-500": "_bill-primary-500_8svpp_114",
|
|
16
|
+
"bill-primary-600-hv_bg_transparent": "_bill-primary-600-hv_bg_transparent_8svpp_126",
|
|
17
|
+
"bill-secondary-800-hv_bg_transparent": "_bill-secondary-800-hv_bg_transparent_8svpp_138",
|
|
18
|
+
"fin-primary-500": "_fin-primary-500_8svpp_150",
|
|
19
|
+
"fin-primary-500-hv_bg_transparent": "_fin-primary-500-hv_bg_transparent_8svpp_188",
|
|
20
|
+
label: a,
|
|
21
|
+
disabled: p
|
|
20
22
|
};
|
|
21
23
|
export {
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
24
|
+
_ as container,
|
|
25
|
+
e as default,
|
|
26
|
+
p as disabled,
|
|
27
|
+
a as label
|
|
26
28
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("../../config/components/borderRadius.cjs"),t=require("../../config/components/font.cjs"),a=require("../../config/components/typography.cjs"),e=require("./RadioCheckboxLabel.module.scss.cjs"),o={borderRadius:r.configBorderRadius,typographyLabel:a.configtypography,typographyDesc:a.configtypography,fonts:t.configFont,variants:{"laba-blue-01":e.default["laba-blue-01"],"blue-50":e.default["blue-50"],"bill-secondary-50":e.default["bill-secondary-50"],"fin-primary-500":e.default["fin-primary-500"],"transparent-text_orange-700":e.default["transparent-text_orange-700"],"transparent-text_green-700":e.default["transparent-text_green-700"]}};exports.configRadioCheckboxLabel=o;
|
|
@@ -1,16 +1,17 @@
|
|
|
1
|
-
import { configBorderRadius as
|
|
2
|
-
import { configFont as
|
|
1
|
+
import { configBorderRadius as a } from "../../config/components/borderRadius.mjs";
|
|
2
|
+
import { configFont as e } from "../../config/components/font.mjs";
|
|
3
3
|
import { configtypography as t } from "../../config/components/typography.mjs";
|
|
4
4
|
import r from "./RadioCheckboxLabel.module.scss.mjs";
|
|
5
5
|
const l = {
|
|
6
|
-
borderRadius:
|
|
6
|
+
borderRadius: a,
|
|
7
7
|
typographyLabel: t,
|
|
8
8
|
typographyDesc: t,
|
|
9
|
-
fonts:
|
|
9
|
+
fonts: e,
|
|
10
10
|
variants: {
|
|
11
11
|
"laba-blue-01": r["laba-blue-01"],
|
|
12
12
|
"blue-50": r["blue-50"],
|
|
13
13
|
"bill-secondary-50": r["bill-secondary-50"],
|
|
14
|
+
"fin-primary-500": r["fin-primary-500"],
|
|
14
15
|
"transparent-text_orange-700": r["transparent-text_orange-700"],
|
|
15
16
|
"transparent-text_green-700": r["transparent-text_green-700"]
|
|
16
17
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e="
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e="_container_10pyz_1",_="_disabled_10pyz_11",a="_label_10pyz_15",t="_desc_10pyz_18",n={container:e,"fin-primary-500":"_fin-primary-500_10pyz_1","bill-secondary-50":"_bill-secondary-50_10pyz_1","laba-blue-01":"_laba-blue-01_10pyz_1","transparent-text_orange-700":"_transparent-text_orange-700_10pyz_1","transparent-text_green-700":"_transparent-text_green-700_10pyz_1","blue-50":"_blue-50_10pyz_1",disabled:_,label:a,desc:t,"same-background":"_same-background_10pyz_21"};exports.container=e;exports.default=n;exports.desc=t;exports.disabled=_;exports.label=a;
|
|
@@ -1,14 +1,15 @@
|
|
|
1
|
-
const e = "
|
|
1
|
+
const e = "_container_10pyz_1", _ = "_disabled_10pyz_11", a = "_label_10pyz_15", n = "_desc_10pyz_18", t = {
|
|
2
2
|
container: e,
|
|
3
|
-
"
|
|
4
|
-
"
|
|
5
|
-
"
|
|
6
|
-
"transparent-
|
|
7
|
-
"
|
|
3
|
+
"fin-primary-500": "_fin-primary-500_10pyz_1",
|
|
4
|
+
"bill-secondary-50": "_bill-secondary-50_10pyz_1",
|
|
5
|
+
"laba-blue-01": "_laba-blue-01_10pyz_1",
|
|
6
|
+
"transparent-text_orange-700": "_transparent-text_orange-700_10pyz_1",
|
|
7
|
+
"transparent-text_green-700": "_transparent-text_green-700_10pyz_1",
|
|
8
|
+
"blue-50": "_blue-50_10pyz_1",
|
|
8
9
|
disabled: _,
|
|
9
10
|
label: a,
|
|
10
11
|
desc: n,
|
|
11
|
-
"same-background": "_same-
|
|
12
|
+
"same-background": "_same-background_10pyz_21"
|
|
12
13
|
};
|
|
13
14
|
export {
|
|
14
15
|
e as container,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const p=require("react/jsx-runtime"),e=require("react"),ne=require("react-select"),te=require("../Popover/Popover.cjs"),re=require("./SelectDropdownContainer.module.scss.cjs"),R=require("../../hooks/useDeepCompareEffect.cjs"),l=require("./SelectDropdownContainer.config.cjs"),ae={"en-US":{"No data found.":"No data found."},"id-ID":{"No data found.":"Tidak ada data."},"zh-CN":{"No data found.":"暂无数据."},"nl-NL":{"No data found.":"Geen data gevonden."}},I=e.forwardRef((C,O)=>{const{width:h,children:V,components:y,classNameContainer:E="",classNameContainerShowSelect:x="",classNameContainerSelect:M="",classNameLabelError:$="",error:b,onChange:m,externalValue:i=!1,defaultValueButtonDropdown:t={},autoClose:q=!0,onMenuOpen:z=()=>{},autoCloseOutside:L=!0,styleInnerPopper:j={},onMenuClose:_=()=>{},zIndexPopper:T=0,id:W="select-dropdown-container",idPopover:k="select-dropdown-container-popover",useAutoPlacement:F,flipOptions:A,autoPlacementOptions:B,withSearch:G=!1,floatingOptions:H={},offsetPopover:U=5,selectProps:J={},errorLabel:K="payhere",controlType:c="payhere",actionValueChange:Q=()=>{},locale:X="id-ID",...Y}=C,r=e.useRef(null),a=e.useRef(null),[Z,v]=e.useState(""),[n,w]=e.useState(!1),[u,d]=e.useState({}),[g,N]=e.useState(0),S=o=>{a.current?.setShow(o),w(o)},ee=()=>{if(i)return C.isMulti?t:[t]},D=o=>{a.current?.handlerShow(o),N(r.current.offsetWidth),w(s=>!s)},P=()=>{L&&a.current?.setShow(!1)},oe=(o,s)=>{q&&(w(!1),a.current?.setShow(!1)),typeof m=="function"&&m(o,s),i||d(o)},f=()=>{r.current&&N(r.current.offsetWidth)};return R.useDeepCompareEffect(()=>{i&&d(t),Q(t)},[i,t]),e.useEffect(()=>{n?z():n||(_(),v(""))},[n]),e.useImperativeHandle(O,()=>({selectValue:u,setSelectValue:d,handlerClose:P,handlerShow:D,show:n,setShow:S}),[n,R.useDeepCompareMemoize(u)]),e.useEffect(()=>(window.addEventListener("resize",f),window.addEventListener("load",f),()=>{window.removeEventListener("resize",f),window.removeEventListener("load",f)}),[r]),p.jsxs("div",{id:W,className:`${re.default.container} ${E} ${n?`${x} open-popover`:null}`,ref:r,children:[V({selectValue:u,setSelectValue:d,handlerClose:P,handlerShow:D,show:n,setShow:S}),p.jsx(te.default,{ref:a,offset:U,useAutoPlacement:F,flipOptions:A,variant:l.configSelectDropdownContainer.variantPopover[c],autoPlacementOptions:B,zIndex:T,styleInnerPopover:j,id:k,width:typeof h=="function"?h(g,u):h||g,className:`${M} ${l.configSelectDropdownContainer.classNamePopover[c]}`,floatingOptions:H,children:p.jsx(ne,{className:"iru-w-full",defaultValue:ee(),inputValue:Z,onInputChange:(o,{action:s})=>{s==="input-change"&&v(o)},openMenuOnFocus:!0,autoFocus:!1,backspaceRemovesValue:!1,components:{IndicatorSeparator:null,...y},controlShouldRenderValue:!1,hideSelectedOptions:!1,isClearable:!1,menuIsOpen:!0,tabSelectsValue:!1,styles:G?l.configSelectDropdownContainer.variant[c]:l.configSelectDropdownContainer.noSearchVariant[c],noOptionsMessage:()=>ae[X]["Rows per page:"],onChange:oe,selectProps:{...J,setShowDropdown:S},...Y})}),p.jsx("div",{className:`${l.configSelectDropdownContainer.error[K]} ${$}`,children:b})]})});I.displayName="SelectDropdownContainer";exports.default=I;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./SelectDropdownContainer.module.scss.cjs"),e=require("./styleConfig.cjs"),o={error:{laba:r.default["error-laba"],payhere:r.default["error-payhere"],bill:r.default["error-bill"]},variant:{laba:e.styleSelectDropdownContainerLaba,payhere:e.styleSelectDropdownContainerPayhere,bill:e.styleSelectDropdownContainerBill},noSearchVariant:{laba:e.styleSelectDropdownContainerNoSearchLaba,payhere:e.styleSelectDropdownContainerNoSearchPayhere,bill:e.styleSelectDropdownContainerNoSearchBill},classNamePopover:{laba:"",payhere:"",bill:"!iru-rounded-xl"}};exports.configSelectDropdownContainer=o;
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./SelectDropdownContainer.module.scss.cjs"),e=require("./styleConfig.cjs"),o={error:{laba:r.default["error-laba"],payhere:r.default["error-payhere"],bill:r.default["error-bill"]},variant:{laba:e.styleSelectDropdownContainerLaba,payhere:e.styleSelectDropdownContainerPayhere,bill:e.styleSelectDropdownContainerBill,fin:e.styleSelectDropdownContainerFin},variantPopover:{laba:"white",payhere:"white",bill:"white",fin:"white-fin"},noSearchVariant:{laba:e.styleSelectDropdownContainerNoSearchLaba,payhere:e.styleSelectDropdownContainerNoSearchPayhere,bill:e.styleSelectDropdownContainerNoSearchBill,fin:e.styleSelectDropdownContainerNoSearchFin},classNamePopover:{laba:"",payhere:"",bill:"!iru-rounded-xl",fin:""}};exports.configSelectDropdownContainer=o;
|
|
@@ -1,27 +1,36 @@
|
|
|
1
1
|
import e from "./SelectDropdownContainer.module.scss.mjs";
|
|
2
|
-
import {
|
|
3
|
-
const
|
|
2
|
+
import { styleSelectDropdownContainerFin as r, styleSelectDropdownContainerBill as o, styleSelectDropdownContainerPayhere as a, styleSelectDropdownContainerLaba as l, styleSelectDropdownContainerNoSearchFin as n, styleSelectDropdownContainerNoSearchBill as t, styleSelectDropdownContainerNoSearchPayhere as i, styleSelectDropdownContainerNoSearchLaba as p } from "./styleConfig.mjs";
|
|
3
|
+
const y = {
|
|
4
4
|
error: {
|
|
5
5
|
laba: e["error-laba"],
|
|
6
6
|
payhere: e["error-payhere"],
|
|
7
7
|
bill: e["error-bill"]
|
|
8
8
|
},
|
|
9
9
|
variant: {
|
|
10
|
-
laba:
|
|
11
|
-
payhere:
|
|
12
|
-
bill:
|
|
10
|
+
laba: l,
|
|
11
|
+
payhere: a,
|
|
12
|
+
bill: o,
|
|
13
|
+
fin: r
|
|
14
|
+
},
|
|
15
|
+
variantPopover: {
|
|
16
|
+
laba: "white",
|
|
17
|
+
payhere: "white",
|
|
18
|
+
bill: "white",
|
|
19
|
+
fin: "white-fin"
|
|
13
20
|
},
|
|
14
21
|
noSearchVariant: {
|
|
15
|
-
laba:
|
|
16
|
-
payhere:
|
|
17
|
-
bill:
|
|
22
|
+
laba: p,
|
|
23
|
+
payhere: i,
|
|
24
|
+
bill: t,
|
|
25
|
+
fin: n
|
|
18
26
|
},
|
|
19
27
|
classNamePopover: {
|
|
20
28
|
laba: "",
|
|
21
29
|
payhere: "",
|
|
22
|
-
bill: "!iru-rounded-xl"
|
|
30
|
+
bill: "!iru-rounded-xl",
|
|
31
|
+
fin: ""
|
|
23
32
|
}
|
|
24
33
|
};
|
|
25
34
|
export {
|
|
26
|
-
|
|
35
|
+
y as configSelectDropdownContainer
|
|
27
36
|
};
|
|
@@ -1,26 +1,39 @@
|
|
|
1
|
-
import { jsxs as
|
|
1
|
+
import { jsxs as ee, jsx as w } from "react/jsx-runtime";
|
|
2
2
|
import e from "react";
|
|
3
|
-
import
|
|
3
|
+
import oe from "react-select";
|
|
4
4
|
import te from "../Popover/Popover.mjs";
|
|
5
|
-
import
|
|
6
|
-
import { useDeepCompareEffect as
|
|
7
|
-
import { configSelectDropdownContainer as
|
|
8
|
-
const
|
|
9
|
-
|
|
5
|
+
import ne from "./SelectDropdownContainer.module.scss.mjs";
|
|
6
|
+
import { useDeepCompareEffect as ae, useDeepCompareMemoize as re } from "../../hooks/useDeepCompareEffect.mjs";
|
|
7
|
+
import { configSelectDropdownContainer as l } from "./SelectDropdownContainer.config.mjs";
|
|
8
|
+
const se = {
|
|
9
|
+
"en-US": {
|
|
10
|
+
"No data found.": "No data found."
|
|
11
|
+
},
|
|
12
|
+
"id-ID": {
|
|
13
|
+
"No data found.": "Tidak ada data."
|
|
14
|
+
},
|
|
15
|
+
"zh-CN": {
|
|
16
|
+
"No data found.": "暂无数据."
|
|
17
|
+
},
|
|
18
|
+
"nl-NL": {
|
|
19
|
+
"No data found.": "Geen data gevonden."
|
|
20
|
+
}
|
|
21
|
+
}, le = e.forwardRef(
|
|
22
|
+
(S, R) => {
|
|
10
23
|
const {
|
|
11
24
|
width: p,
|
|
12
|
-
children:
|
|
13
|
-
components:
|
|
14
|
-
classNameContainer:
|
|
15
|
-
classNameContainerShowSelect:
|
|
16
|
-
classNameContainerSelect:
|
|
17
|
-
classNameLabelError:
|
|
18
|
-
error:
|
|
19
|
-
onChange:
|
|
20
|
-
externalValue:
|
|
25
|
+
children: V,
|
|
26
|
+
components: y,
|
|
27
|
+
classNameContainer: O = "",
|
|
28
|
+
classNameContainerShowSelect: D = "",
|
|
29
|
+
classNameContainerSelect: E = "",
|
|
30
|
+
classNameLabelError: $ = "",
|
|
31
|
+
error: z,
|
|
32
|
+
onChange: v,
|
|
33
|
+
externalValue: i = !1,
|
|
21
34
|
defaultValueButtonDropdown: n = {},
|
|
22
|
-
autoClose:
|
|
23
|
-
onMenuOpen:
|
|
35
|
+
autoClose: L = !0,
|
|
36
|
+
onMenuOpen: x = () => {
|
|
24
37
|
},
|
|
25
38
|
autoCloseOutside: M = !0,
|
|
26
39
|
styleInnerPopper: b = {},
|
|
@@ -32,115 +45,117 @@ const ae = e.forwardRef(
|
|
|
32
45
|
useAutoPlacement: T,
|
|
33
46
|
flipOptions: A,
|
|
34
47
|
autoPlacementOptions: B,
|
|
35
|
-
withSearch:
|
|
36
|
-
floatingOptions:
|
|
37
|
-
offsetPopover:
|
|
38
|
-
selectProps:
|
|
39
|
-
errorLabel:
|
|
40
|
-
controlType:
|
|
41
|
-
actionValueChange:
|
|
48
|
+
withSearch: G = !1,
|
|
49
|
+
floatingOptions: H = {},
|
|
50
|
+
offsetPopover: U = 5,
|
|
51
|
+
selectProps: q = {},
|
|
52
|
+
errorLabel: J = "payhere",
|
|
53
|
+
controlType: c = "payhere",
|
|
54
|
+
actionValueChange: K = () => {
|
|
42
55
|
},
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
56
|
+
locale: Q = "id-ID",
|
|
57
|
+
...X
|
|
58
|
+
} = S, a = e.useRef(null), r = e.useRef(null), [Y, C] = e.useState(""), [t, h] = e.useState(!1), [u, d] = e.useState({}), [N, P] = e.useState(0), m = (o) => {
|
|
59
|
+
r.current?.setShow(o), h(o);
|
|
60
|
+
}, Z = () => {
|
|
61
|
+
if (i)
|
|
48
62
|
return S.isMulti ? n : [n];
|
|
49
|
-
},
|
|
50
|
-
|
|
51
|
-
},
|
|
52
|
-
M &&
|
|
53
|
-
},
|
|
54
|
-
|
|
55
|
-
},
|
|
56
|
-
|
|
63
|
+
}, g = (o) => {
|
|
64
|
+
r.current?.handlerShow(o), P(a.current.offsetWidth), h((s) => !s);
|
|
65
|
+
}, I = () => {
|
|
66
|
+
M && r.current?.setShow(!1);
|
|
67
|
+
}, _ = (o, s) => {
|
|
68
|
+
L && (h(!1), r.current?.setShow(!1)), typeof v == "function" && v(o, s), i || d(o);
|
|
69
|
+
}, f = () => {
|
|
70
|
+
a.current && P(a.current.offsetWidth);
|
|
57
71
|
};
|
|
58
|
-
return
|
|
59
|
-
|
|
60
|
-
}, [
|
|
61
|
-
|
|
62
|
-
}, [
|
|
63
|
-
|
|
72
|
+
return ae(() => {
|
|
73
|
+
i && d(n), K(n);
|
|
74
|
+
}, [i, n]), e.useEffect(() => {
|
|
75
|
+
t ? x() : t || (W(), C(""));
|
|
76
|
+
}, [t]), e.useImperativeHandle(
|
|
77
|
+
R,
|
|
64
78
|
() => ({
|
|
65
|
-
selectValue:
|
|
66
|
-
setSelectValue:
|
|
67
|
-
handlerClose:
|
|
68
|
-
handlerShow:
|
|
69
|
-
show:
|
|
79
|
+
selectValue: u,
|
|
80
|
+
setSelectValue: d,
|
|
81
|
+
handlerClose: I,
|
|
82
|
+
handlerShow: g,
|
|
83
|
+
show: t,
|
|
70
84
|
setShow: m
|
|
71
85
|
}),
|
|
72
|
-
[
|
|
73
|
-
), e.useEffect(() => (window.addEventListener("resize",
|
|
74
|
-
window.removeEventListener("resize",
|
|
75
|
-
}), [
|
|
86
|
+
[t, re(u)]
|
|
87
|
+
), e.useEffect(() => (window.addEventListener("resize", f), window.addEventListener("load", f), () => {
|
|
88
|
+
window.removeEventListener("resize", f), window.removeEventListener("load", f);
|
|
89
|
+
}), [a]), /* @__PURE__ */ ee(
|
|
76
90
|
"div",
|
|
77
91
|
{
|
|
78
92
|
id: k,
|
|
79
|
-
className: `${
|
|
80
|
-
ref:
|
|
93
|
+
className: `${ne.container} ${O} ${t ? `${D} open-popover` : null}`,
|
|
94
|
+
ref: a,
|
|
81
95
|
children: [
|
|
82
|
-
|
|
83
|
-
selectValue:
|
|
84
|
-
setSelectValue:
|
|
85
|
-
handlerClose:
|
|
86
|
-
handlerShow:
|
|
87
|
-
show:
|
|
96
|
+
V({
|
|
97
|
+
selectValue: u,
|
|
98
|
+
setSelectValue: d,
|
|
99
|
+
handlerClose: I,
|
|
100
|
+
handlerShow: g,
|
|
101
|
+
show: t,
|
|
88
102
|
setShow: m
|
|
89
103
|
}),
|
|
90
104
|
/* @__PURE__ */ w(
|
|
91
105
|
te,
|
|
92
106
|
{
|
|
93
|
-
ref:
|
|
94
|
-
offset:
|
|
107
|
+
ref: r,
|
|
108
|
+
offset: U,
|
|
95
109
|
useAutoPlacement: T,
|
|
96
110
|
flipOptions: A,
|
|
111
|
+
variant: l.variantPopover[c],
|
|
97
112
|
autoPlacementOptions: B,
|
|
98
113
|
zIndex: j,
|
|
99
114
|
styleInnerPopover: b,
|
|
100
115
|
id: F,
|
|
101
|
-
width: typeof p == "function" ? p(
|
|
102
|
-
className: `${
|
|
103
|
-
floatingOptions:
|
|
116
|
+
width: typeof p == "function" ? p(N, u) : p || N,
|
|
117
|
+
className: `${E} ${l.classNamePopover[c]}`,
|
|
118
|
+
floatingOptions: H,
|
|
104
119
|
children: /* @__PURE__ */ w(
|
|
105
|
-
|
|
120
|
+
oe,
|
|
106
121
|
{
|
|
107
122
|
className: "iru-w-full",
|
|
108
|
-
defaultValue:
|
|
109
|
-
inputValue:
|
|
110
|
-
onInputChange: (
|
|
111
|
-
s === "input-change" &&
|
|
123
|
+
defaultValue: Z(),
|
|
124
|
+
inputValue: Y,
|
|
125
|
+
onInputChange: (o, { action: s }) => {
|
|
126
|
+
s === "input-change" && C(o);
|
|
112
127
|
},
|
|
113
128
|
openMenuOnFocus: !0,
|
|
114
129
|
autoFocus: !1,
|
|
115
130
|
backspaceRemovesValue: !1,
|
|
116
131
|
components: {
|
|
117
132
|
IndicatorSeparator: null,
|
|
118
|
-
...
|
|
133
|
+
...y
|
|
119
134
|
},
|
|
120
135
|
controlShouldRenderValue: !1,
|
|
121
136
|
hideSelectedOptions: !1,
|
|
122
137
|
isClearable: !1,
|
|
123
138
|
menuIsOpen: !0,
|
|
124
139
|
tabSelectsValue: !1,
|
|
125
|
-
styles:
|
|
126
|
-
noOptionsMessage: () => "
|
|
127
|
-
onChange:
|
|
140
|
+
styles: G ? l.variant[c] : l.noSearchVariant[c],
|
|
141
|
+
noOptionsMessage: () => se[Q]["Rows per page:"],
|
|
142
|
+
onChange: _,
|
|
128
143
|
selectProps: {
|
|
129
|
-
...
|
|
144
|
+
...q,
|
|
130
145
|
setShowDropdown: m
|
|
131
146
|
},
|
|
132
|
-
...
|
|
147
|
+
...X
|
|
133
148
|
}
|
|
134
149
|
)
|
|
135
150
|
}
|
|
136
151
|
),
|
|
137
|
-
/* @__PURE__ */ w("div", { className: `${
|
|
152
|
+
/* @__PURE__ */ w("div", { className: `${l.error[J]} ${$}`, children: z })
|
|
138
153
|
]
|
|
139
154
|
}
|
|
140
155
|
);
|
|
141
156
|
}
|
|
142
157
|
);
|
|
143
|
-
|
|
158
|
+
le.displayName = "SelectDropdownContainer";
|
|
144
159
|
export {
|
|
145
|
-
|
|
160
|
+
le as default
|
|
146
161
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e={control:o=>({...o,border:"1px solid #D6D6D6","&:hover":{borderColor:"#0163C8"},borderRadius:"4px",outline:"none",boxShadow:"none",color:"#898989",backgroundColor:"white",margin:"0px",cursor:"text",minHeight:32,fontSize:"12px",lineHeight:"16px",fontFamily:"Lato"}),dropdownIndicator:o=>({...o,padding:"0px 8px"}),menu:o=>({...o,position:"static",boxShadow:"none",marginTop:"0px"}),option:(o,i)=>({...o,fontSize:"14px",lineHeight:"22px",fontFamily:"Lato",cursor:"pointer",background:i.isSelected?"#F0F7FF":"white",color:i.isSelected?"#0163C8":o.color,"&:hover":{background:i.isDisabled?"":"#F0F7FF",color:i.isDisabled?"":"#0163C8",cursor:i.isDisabled?"default":""}}),group:o=>({...o,padding:0}),placeholder:o=>({...o,fontSize:"12px",lineHeight:"16px",fontFamily:"Lato"})},r={control:o=>({...o,border:"1px solid #BDBDBD","&:hover":{borderColor:"#64B5F6"},borderRadius:"6px",outline:"none",color:"#212121",backgroundColor:"white",margin:"0px",cursor:"text",minHeight:38,fontSize:"14px",lineHeight:"22px",fontFamily:"Inter",marginBottom:"5px"}),dropdownIndicator:o=>({...o,padding:"0px 8px"}),menu:o=>({...o,position:"static",boxShadow:"none",marginTop:"0px"}),option:(o,i)=>({...o,fontSize:"14px",lineHeight:"22px",fontFamily:"Inter",cursor:"pointer",background:i.isSelected?"#E1F5FE":"white",color:i.isSelected?"#1565C0":o.color,"&:hover":{background:i.isDisabled?"":"#E1F5FE",color:i.isDisabled?"":"#1565C0",cursor:i.isDisabled?"default":""}}),group:o=>({...o,padding:0}),placeholder:o=>({...o,fontSize:"14px",lineHeight:"22px",fontFamily:"Inter"})},n={control:o=>({...o,border:"1px solid #BDBDBD","&:hover":{borderColor:"#64B5F6"},borderRadius:"6px",outline:"none",color:"#212121",backgroundColor:"white",margin:"0px",cursor:"text",minHeight:38,fontSize:"14px",lineHeight:"22px",fontFamily:"PJakartaSans",marginBottom:"5px"}),dropdownIndicator:o=>({...o,padding:"0px 8px"}),menu:o=>({...o,position:"static",boxShadow:"none",marginTop:"0px",borderRadius:"12px"}),menuList:o=>({...o,borderRadius:"12px"}),option:(o,i)=>({...o,fontSize:"14px",lineHeight:"22px",fontFamily:"PJakartaSans",cursor:"pointer",background:i.isSelected?"#F0FEFD":"white",color:i.isSelected?"#2F7E79":o.color,"&:hover":{background:i.isDisabled?"":"#F0FEFD",color:i.isDisabled?"":"#2F7E79",cursor:i.isDisabled?"default":""}}),group:o=>({...o,padding:0}),placeholder:o=>({...o,fontSize:"14px",lineHeight:"22px",fontFamily:"PJakartaSans"})},d={control:o=>({...o,border:"1px solid #29B6F6","&:hover":{borderColor:"#29B6F6"},borderRadius:"8px",outline:"none",backgroundColor:"#ECEFF1",margin:"0px",cursor:"text",minHeight:38,fontSize:"14px",lineHeight:"22px",fontFamily:"PJakartaSans",marginBottom:"5px",'html[data-color-mode="dark"] &':{backgroundColor:"#1B3049"}}),dropdownIndicator:o=>({...o,padding:"0px 8px",color:"#616161"}),menu:o=>({...o,position:"static",boxShadow:"none",marginTop:"0px",marginBottom:"0px",borderBottomRightRadius:"12px",borderBottomLeftRadius:"12px",background:"white",'html[data-color-mode="dark"] &':{background:"#0E1824"}}),noOptionsMessage:o=>({...o,color:"#78909C",fontFamily:"PJakartaSans",'html[data-color-mode="dark"] &':{color:"#78909C"}}),menuList:o=>({...o,borderRadius:"4px"}),option:(o,i)=>({...o,fontSize:"14px",lineHeight:"22px",fontWeight:500,fontFamily:"PJakartaSans",cursor:"pointer",borderRadius:"4px",background:i.isSelected?"#CFD8DC":"white",color:i.isDisabled?"#90A4AE":"#0A121B","&:hover":{background:i.isDisabled?"":"#CFD8DC",cursor:i.isDisabled?"default":""},'html[data-color-mode="dark"] &':{background:i.isSelected?"#223C5B":"#0E1824",color:i.isDisabled?"#546E7A":"white","&:hover":{background:i.isDisabled?"":"#223C5B"}}}),group:o=>({...o,padding:0}),input:o=>({...o,color:"#0A121B",'html[data-color-mode="dark"] &':{color:"white !important",caretColor:"white !important","& input":{color:"white !important"}}}),placeholder:o=>({...o,color:"#78909C",fontSize:"14px",lineHeight:"22px",fontFamily:"PJakartaSans",'html[data-color-mode="dark"] &':{color:"#78909C"}})},t={control:()=>({display:"none"}),dropdownIndicator:o=>({...o,padding:"0px 8px"}),menu:o=>({...o,position:"static",boxShadow:"none",marginTop:"0px"}),option:(o,i)=>({...o,fontSize:"14px",lineHeight:"22px",fontFamily:"Lato",cursor:"pointer",background:i.isSelected?"#F0F7FF":"white",color:i.isSelected?"#0163C8":o.color,"&:hover":{background:i.isDisabled?"":"#F0F7FF",color:i.isDisabled?"":"#0163C8",cursor:i.isDisabled?"default":""}}),group:o=>({...o,padding:0}),placeholder:o=>({...o,fontSize:"12px",lineHeight:"16px",fontFamily:"Lato"})},a={control:()=>({display:"none"}),dropdownIndicator:o=>({...o,padding:"0px 8px"}),menu:o=>({...o,position:"static",boxShadow:"none",marginTop:"0px"}),option:(o,i)=>({...o,fontSize:"14px",lineHeight:"22px",fontFamily:"Inter",cursor:"pointer",background:i.isSelected?"#E1F5FE":"white",color:i.isSelected?"#1565C0":o.color,"&:hover":{background:i.isDisabled?"":"#E1F5FE",color:i.isDisabled?"":"#1565C0",cursor:i.isDisabled?"default":""}}),group:o=>({...o,padding:0}),placeholder:o=>({...o,fontSize:"14px",lineHeight:"22px",fontFamily:"Inter"})},l={control:()=>({display:"none"}),dropdownIndicator:o=>({...o,padding:"0px 8px"}),menu:o=>({...o,position:"static",boxShadow:"none",marginTop:"0px",borderRadius:"12px"}),menuList:o=>({...o,borderRadius:"12px"}),option:(o,i)=>({...o,fontSize:"14px",lineHeight:"22px",fontFamily:"PJakartaSans",fontWeight:"500",cursor:"pointer",background:i.isSelected?"#F0FEFD":"white",color:i.isSelected?"#2F7E79":o.color,"&:hover":{background:i.isDisabled?"":"#F0FEFD",color:i.isDisabled?"":"#2F7E79",cursor:i.isDisabled?"default":""}}),group:o=>({...o,padding:0}),placeholder:o=>({...o,fontSize:"14px",lineHeight:"22px",fontFamily:"PJakartaSans"})},p={control:()=>({display:"none"}),dropdownIndicator:o=>({...o,padding:"0px 8px"}),menu:o=>({...o,position:"static",boxShadow:"none",marginTop:"0px",marginBottom:"0px",borderBottomRightRadius:"12px",borderBottomLeftRadius:"12px"}),menuList:o=>({...o,borderRadius:"4px"}),option:(o,i)=>({...o,fontSize:"14px",lineHeight:"22px",fontFamily:"PJakartaSans",fontWeight:"500",cursor:"pointer",borderRadius:"4px",background:i.isSelected?"#CFD8DC":"white",color:i.isDisabled?"#90A4AE":"#0A121B","&:hover":{background:i.isDisabled?"":"#CFD8DC",cursor:i.isDisabled?"default":""},'html[data-color-mode="dark"] &':{background:i.isSelected?"#223C5B":"#0E1824",color:i.isDisabled?"#546E7A":"white","&:hover":{background:i.isDisabled?"":"#223C5B"}}}),group:o=>({...o,padding:0})};exports.styleSelectDropdownContainerBill=n;exports.styleSelectDropdownContainerFin=d;exports.styleSelectDropdownContainerLaba=e;exports.styleSelectDropdownContainerNoSearchBill=l;exports.styleSelectDropdownContainerNoSearchFin=p;exports.styleSelectDropdownContainerNoSearchLaba=t;exports.styleSelectDropdownContainerNoSearchPayhere=a;exports.styleSelectDropdownContainerPayhere=r;
|