@cagatayfdn/flora-components 0.0.103 → 0.0.105

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.
@@ -0,0 +1 @@
1
+ ._iconBox_18b0e_1{display:inline-flex;justify-content:center;align-items:center;width:36px;height:36px;font-size:13px;border-radius:5px;padding:12px 0;border:1px solid transparent;outline:none;cursor:pointer}._iconBox_18b0e_1:focus{box-shadow:inherit}._iconBox_18b0e_1 i{width:13px;height:13px}._iconBox__primary_18b0e_21{color:#fff;background-color:#4482ff;border-color:#c8daec}._iconBox__secondary_18b0e_26{border-color:#c8daec;background-color:#fff;color:#717a8e}
@@ -6,24 +6,24 @@ import P from "./components/Button/Button.js";
6
6
  import L from "./components/Heading/Heading.js";
7
7
  import k from "./components/Pager/Pager.js";
8
8
  import { S as b } from "./Select-DcLZCXNo.js";
9
- import { u as z } from "./useTranslation-CnCPcxVj.js";
10
- import { T as F } from "./Trans-B4ILpbwK.js";
11
- import './TableHeader.css';const B = "_wrapper_1tluw_1", D = "_header_1tluw_4", S = "_title_1tluw_7", K = "_subTitle_1tluw_13", M = "_table_1tluw_18", Y = "_fixed_1tluw_24", q = "_light_1tluw_50", C = "_fixedHeader_1tluw_55", J = "_dark_1tluw_65", Q = "_tableWrap_1tluw_71", U = "_actionWrap_1tluw_116", V = "_tableLoading_1tluw_120", X = "_selectedAction_1tluw_130", Z = "_rightGroup_1tluw_137", $ = "_pageSizeWrap_1tluw_141", I = "_pager_1tluw_151", O = "_size_1tluw_155", ee = "_noResult_1tluw_159", te = "_scrollWrap_1tluw_168", se = "_justifyContentEnd_1tluw_172", ae = "_width100_1tluw_176", t = {
12
- wrapper: B,
13
- header: D,
14
- title: S,
15
- subTitle: K,
16
- table: M,
17
- fixed: Y,
18
- light: q,
19
- fixedHeader: C,
20
- dark: J,
21
- tableWrap: Q,
22
- actionWrap: U,
23
- tableLoading: V,
24
- selectedAction: X,
25
- rightGroup: Z,
26
- pageSizeWrap: $,
9
+ import { u as F } from "./useTranslation-CnCPcxVj.js";
10
+ import { T as B } from "./Trans-B4ILpbwK.js";
11
+ import './TableHeader.css';const D = "_wrapper_1tluw_1", z = "_header_1tluw_4", K = "_title_1tluw_7", M = "_subTitle_1tluw_13", Y = "_table_1tluw_18", q = "_fixed_1tluw_24", J = "_light_1tluw_50", Q = "_fixedHeader_1tluw_55", S = "_dark_1tluw_65", U = "_tableWrap_1tluw_71", V = "_actionWrap_1tluw_116", X = "_tableLoading_1tluw_120", Z = "_selectedAction_1tluw_130", $ = "_rightGroup_1tluw_137", C = "_pageSizeWrap_1tluw_141", I = "_pager_1tluw_151", O = "_size_1tluw_155", ee = "_noResult_1tluw_159", te = "_scrollWrap_1tluw_168", se = "_justifyContentEnd_1tluw_172", ae = "_width100_1tluw_176", t = {
12
+ wrapper: D,
13
+ header: z,
14
+ title: K,
15
+ subTitle: M,
16
+ table: Y,
17
+ fixed: q,
18
+ light: J,
19
+ fixedHeader: Q,
20
+ dark: S,
21
+ tableWrap: U,
22
+ actionWrap: V,
23
+ tableLoading: X,
24
+ selectedAction: Z,
25
+ rightGroup: $,
26
+ pageSizeWrap: C,
27
27
  pager: I,
28
28
  size: O,
29
29
  noResult: ee,
@@ -37,34 +37,34 @@ import './TableHeader.css';const B = "_wrapper_1tluw_1", D = "_header_1tluw_4",
37
37
  { value: "100", label: "100" },
38
38
  { value: "250", label: "250" }
39
39
  ], me = ({
40
- totalCount: i = 0,
40
+ totalCount: n = 0,
41
41
  currentPage: f,
42
42
  title: l,
43
43
  actionOnChange: r,
44
44
  className: h,
45
45
  pagerOnChange: j,
46
46
  pageSizeOnChange: d,
47
- pagerVisible: g = !0,
48
- pageSizeVisible: v = !0,
49
- pageSize: a = 10,
47
+ pagerVisible: v = !0,
48
+ pageSizeVisible: g = !0,
49
+ pageSize: s = 10,
50
50
  actionItems: o,
51
51
  pageSizeItems: W = le,
52
- headerLeftItem: n,
52
+ headerLeftItem: i,
53
53
  customItem: c,
54
54
  appearance: T,
55
55
  showItemsText: N
56
56
  }) => {
57
- const { t: _ } = z(), [y, u] = x(!0), [A, p] = x({
58
- label: a,
59
- value: a
60
- }), H = (s) => [
61
- { value: "exportexel", label: s("text.excel_export") }
62
- ], E = (s) => {
63
- u(!s), r && r(s);
57
+ const { t: _ } = F(), [y, u] = x(!0), [A, p] = x({
58
+ label: s,
59
+ value: s
60
+ }), H = (a) => [
61
+ { value: "exportexel", label: a("text.excel_export") }
62
+ ], E = (a) => {
63
+ u(!a), r && r(a);
64
64
  };
65
65
  return o = o || H(_), G(() => {
66
- p({ label: a, value: a });
67
- }, [a]), /* @__PURE__ */ e.jsxs(
66
+ p({ label: s, value: s });
67
+ }, [s]), /* @__PURE__ */ e.jsxs(
68
68
  "div",
69
69
  {
70
70
  "data-testid": "tableheader-container",
@@ -76,7 +76,7 @@ import './TableHeader.css';const B = "_wrapper_1tluw_1", D = "_header_1tluw_4",
76
76
  l && /* @__PURE__ */ e.jsxs("div", { children: [
77
77
  /* @__PURE__ */ e.jsx(L, { className: t.title, children: l }),
78
78
  /* @__PURE__ */ e.jsxs("p", { className: t.subTitle, children: [
79
- i,
79
+ n,
80
80
  " ",
81
81
  _("text.results_listing")
82
82
  ] })
@@ -86,8 +86,8 @@ import './TableHeader.css';const B = "_wrapper_1tluw_1", D = "_header_1tluw_4",
86
86
  "div",
87
87
  {
88
88
  className: m(t.actionWrap, {
89
- [t.justifyContentEnd]: !n,
90
- [t.width100]: n
89
+ [t.justifyContentEnd]: !i,
90
+ [t.width100]: i
91
91
  }),
92
92
  children: /* @__PURE__ */ e.jsxs(e.Fragment, { children: [
93
93
  r && /* @__PURE__ */ e.jsxs("div", { className: t.selectedAction, children: [
@@ -109,9 +109,9 @@ import './TableHeader.css';const B = "_wrapper_1tluw_1", D = "_header_1tluw_4",
109
109
  }
110
110
  )
111
111
  ] }),
112
- n && n,
112
+ i && i,
113
113
  /* @__PURE__ */ e.jsxs("div", { className: t.rightGroup, children: [
114
- v && /* @__PURE__ */ e.jsxs("div", { className: t.pageSizeWrap, children: [
114
+ g && n > s && /* @__PURE__ */ e.jsxs("div", { className: t.pageSizeWrap, children: [
115
115
  /* @__PURE__ */ e.jsx(
116
116
  b,
117
117
  {
@@ -120,26 +120,26 @@ import './TableHeader.css';const B = "_wrapper_1tluw_1", D = "_header_1tluw_4",
120
120
  items: W,
121
121
  className: t.size,
122
122
  showPlaceholder: !1,
123
- onAddItem: ({ item: s }) => {
124
- p(s), d && d(s.value);
123
+ onAddItem: ({ item: a }) => {
124
+ p(a), d && d(a.value);
125
125
  },
126
126
  appearance: w.LIGHT
127
127
  }
128
128
  ),
129
129
  /* @__PURE__ */ e.jsx("span", { children: /* @__PURE__ */ e.jsx(
130
- F,
130
+ B,
131
131
  {
132
132
  i18nKey: "text.show",
133
133
  values: { title: N || l }
134
134
  }
135
135
  ) })
136
136
  ] }),
137
- g && i > 0 && /* @__PURE__ */ e.jsx(
137
+ v && n > s && /* @__PURE__ */ e.jsx(
138
138
  k,
139
139
  {
140
140
  currentPage: f,
141
- pageSize: a,
142
- totalCount: i,
141
+ pageSize: s,
142
+ totalCount: n,
143
143
  onChange: j,
144
144
  appearance: T,
145
145
  className: t.pager
@@ -0,0 +1,13 @@
1
+ import { j as n } from "../../jsx-runtime-BcAkpsdy.js";
2
+ import { c as r } from "../../index-BHf7G3IG.js";
3
+ import i from "../Icon/index.js";
4
+ import '../../IconBox.css';const x = "_iconBox_18b0e_1", a = "_iconBox__primary_18b0e_21", e = "_iconBox__secondary_18b0e_26", c = {
5
+ iconBox: x,
6
+ iconBox__primary: a,
7
+ iconBox__secondary: e
8
+ }, p = ({ icon: s, onClick: _, type: o = "secondary" }) => /* @__PURE__ */ n.jsx("button", { className: r(c.iconBox, {
9
+ [c[`iconBox__${o}`]]: o
10
+ }), onClick: _, children: /* @__PURE__ */ n.jsx(i, { name: s }) });
11
+ export {
12
+ p as default
13
+ };
@@ -2,7 +2,7 @@ import { j as s } from "../../jsx-runtime-BcAkpsdy.js";
2
2
  import { useState as Q, useEffect as Y } from "react";
3
3
  import Z from "../NoResult/NoResult.js";
4
4
  import { c as g } from "../../index-BHf7G3IG.js";
5
- import { s as c, T as H } from "../../TableHeader-Cjx9ZwYH.js";
5
+ import { s as c, T as H } from "../../TableHeader-CZpy30xO.js";
6
6
  import { ThemeAppearance as L, AppearanceSpinner as T } from "../../enums/appearance.js";
7
7
  import A from "../Checkbox/Checkbox.js";
8
8
  import I from "../Loading/Loading.js";
@@ -1,7 +1,7 @@
1
1
  import "../../jsx-runtime-BcAkpsdy.js";
2
2
  import "react";
3
3
  import "../../index-BHf7G3IG.js";
4
- import { T as u } from "../../TableHeader-Cjx9ZwYH.js";
4
+ import { T as u } from "../../TableHeader-CZpy30xO.js";
5
5
  import "../../enums/appearance.js";
6
6
  import "../Button/Button.js";
7
7
  import "../Heading/Heading.js";
@@ -6,14 +6,14 @@ import { default as u } from "./ActionButton/ActionButton.js";
6
6
  import { default as n } from "./AlertCard/AlertCard.js";
7
7
  import { default as C } from "./AuthUserCan/Permission.js";
8
8
  import { default as T } from "./Autocomplete/Autocomplete.js";
9
- import { default as I } from "./Card/Card.js";
9
+ import { default as S } from "./Card/Card.js";
10
10
  import { default as P } from "./Charts/index.js";
11
11
  import { default as w } from "./Checkbox/Checkbox.js";
12
12
  import { default as A } from "./Config/Config.js";
13
13
  import { default as N } from "./Confirm/Confirm.js";
14
- import { default as F } from "./ContentHeader/ContentHeader.js";
15
- import { default as R } from "./ContentLoader/ContentLoader.js";
16
- import { default as y } from "./Countdown/Countdown.js";
14
+ import { default as B } from "./ContentHeader/ContentHeader.js";
15
+ import { default as M } from "./ContentLoader/ContentLoader.js";
16
+ import { default as k } from "./Countdown/Countdown.js";
17
17
  import { default as U } from "./Datepicker/Datepicker.js";
18
18
  import { default as E } from "./Divider/Divider.js";
19
19
  import { default as W } from "./Drawer/index.js";
@@ -26,40 +26,41 @@ import { default as _ } from "./Grid/Column.js";
26
26
  import { default as oo } from "./Grid/Row.js";
27
27
  import { default as ro } from "./Heading/Heading.js";
28
28
  import { default as ao } from "./Icon/index.js";
29
- import { default as lo } from "./InfiniteScroll/InfiniteScroll.js";
30
- import { default as mo } from "./InfoBoxList/InfoBoxList.js";
31
- import { createConnectedService as so } from "./InfoBoxList/helper.js";
32
- import { default as io } from "./InfoDate/InfoDate.js";
33
- import { InfoText as co } from "./InfoText/InfoText.js";
34
- import { default as go } from "./Input/Input.js";
35
- import { default as So } from "./Label/Label.js";
36
- import { default as Lo } from "./Loading/Loading.js";
37
- import { default as ho } from "./Modal/Modal.js";
38
- import { default as bo } from "./NavigatorCard/index.js";
39
- import { default as Do } from "./NoResult/NoResult.js";
40
- import { Notification as vo } from "./Notification/Notification.js";
41
- import { default as Mo } from "./PageWrapper/PageWrap.js";
42
- import { default as ko } from "./Pager/Pager.js";
43
- import { default as Bo } from "./Panel/Panel.js";
44
- import { default as Ho } from "./PermaLink/PermaLink.js";
45
- import { default as Vo, RadioList as Wo } from "./Radio/Radio.js";
46
- import { default as qo } from "./ResultError/ResultError.js";
47
- import { default as Go } from "./ScrollContainer/ScrollContainer.js";
48
- import { default as Ko } from "./Select/NoData.js";
49
- import { S as Qo } from "../Select-DcLZCXNo.js";
50
- import { default as Yo } from "./Sidebar/index.js";
51
- import { M as _o } from "../MenuItem-DAf7NU3h.js";
52
- import { default as oe } from "./StatusTag/StatusTag.js";
53
- import { default as re } from "./StatusTypography/StatusTypography.js";
54
- import { default as ae } from "./Stepper/Stepper.js";
55
- import { default as le } from "./Switch/Switch.js";
56
- import { default as pe } from "./Tab/Tab.js";
57
- import { default as xe } from "./Table/Table.js";
58
- import { T as ue } from "../TableHeader-Cjx9ZwYH.js";
59
- import { default as ne } from "./Textarea/Textarea.js";
60
- import { default as Ce } from "./Tooltip/Tooltip.js";
61
- import { default as Te } from "./TypographyText/TypographyText.js";
62
- import { default as Ie } from "./ValidationError/ValidationError.js";
29
+ import { default as lo } from "./IconBox/IconBox.js";
30
+ import { default as mo } from "./InfiniteScroll/InfiniteScroll.js";
31
+ import { default as so } from "./InfoBoxList/InfoBoxList.js";
32
+ import { createConnectedService as io } from "./InfoBoxList/helper.js";
33
+ import { default as co } from "./InfoDate/InfoDate.js";
34
+ import { InfoText as go } from "./InfoText/InfoText.js";
35
+ import { default as Io } from "./Input/Input.js";
36
+ import { default as Lo } from "./Label/Label.js";
37
+ import { default as ho } from "./Loading/Loading.js";
38
+ import { default as bo } from "./Modal/Modal.js";
39
+ import { default as Do } from "./NavigatorCard/index.js";
40
+ import { default as vo } from "./NoResult/NoResult.js";
41
+ import { Notification as Fo } from "./Notification/Notification.js";
42
+ import { default as Ro } from "./PageWrapper/PageWrap.js";
43
+ import { default as yo } from "./Pager/Pager.js";
44
+ import { default as Ho } from "./Panel/Panel.js";
45
+ import { default as Vo } from "./PermaLink/PermaLink.js";
46
+ import { default as jo, RadioList as qo } from "./Radio/Radio.js";
47
+ import { default as Go } from "./ResultError/ResultError.js";
48
+ import { default as Ko } from "./ScrollContainer/ScrollContainer.js";
49
+ import { default as Qo } from "./Select/NoData.js";
50
+ import { S as Yo } from "../Select-DcLZCXNo.js";
51
+ import { default as _o } from "./Sidebar/index.js";
52
+ import { M as oe } from "../MenuItem-DAf7NU3h.js";
53
+ import { default as re } from "./StatusTag/StatusTag.js";
54
+ import { default as ae } from "./StatusTypography/StatusTypography.js";
55
+ import { default as le } from "./Stepper/Stepper.js";
56
+ import { default as pe } from "./Switch/Switch.js";
57
+ import { default as xe } from "./Tab/Tab.js";
58
+ import { default as ue } from "./Table/Table.js";
59
+ import { T as ne } from "../TableHeader-CZpy30xO.js";
60
+ import { default as Ce } from "./Textarea/Textarea.js";
61
+ import { default as Te } from "./Tooltip/Tooltip.js";
62
+ import { default as Se } from "./TypographyText/TypographyText.js";
63
+ import { default as Pe } from "./ValidationError/ValidationError.js";
63
64
  export {
64
65
  m as Accordion,
65
66
  x as AccordionItem,
@@ -67,15 +68,15 @@ export {
67
68
  n as AlertCard,
68
69
  T as Autocomplete,
69
70
  r as Button,
70
- I as Card,
71
+ S as Card,
71
72
  P as Chart,
72
73
  w as Checkbox,
73
74
  _ as Column,
74
75
  A as Config,
75
76
  N as Confirm,
76
- F as ContentHeader,
77
- R as ContentLoader,
78
- y as Countdown,
77
+ B as ContentHeader,
78
+ M as ContentLoader,
79
+ k as Countdown,
79
80
  U as Datepicker,
80
81
  E as Divider,
81
82
  W as Drawer,
@@ -86,44 +87,45 @@ export {
86
87
  Y as FileUploadPreviewModal,
87
88
  ro as Heading,
88
89
  ao as Icon,
89
- lo as InfiniteScroll,
90
- mo as InfoBoxList,
91
- io as InfoDate,
92
- co as InfoText,
93
- go as Input,
94
- So as Label,
95
- Lo as Loading,
96
- _o as MenuItem,
97
- ho as Modal,
98
- bo as NavigatorCard,
90
+ lo as IconBox,
91
+ mo as InfiniteScroll,
92
+ so as InfoBoxList,
93
+ co as InfoDate,
94
+ go as InfoText,
95
+ Io as Input,
96
+ Lo as Label,
97
+ ho as Loading,
98
+ oe as MenuItem,
99
+ bo as Modal,
100
+ Do as NavigatorCard,
99
101
  a as NiceModal,
100
- Ko as NoData,
101
- Do as NoResult,
102
- vo as Notification,
103
- Mo as PageWrapper,
104
- ko as Pager,
105
- Bo as Panel,
102
+ Qo as NoData,
103
+ vo as NoResult,
104
+ Fo as Notification,
105
+ Ro as PageWrapper,
106
+ yo as Pager,
107
+ Ho as Panel,
106
108
  l as PermFallBack,
107
- Ho as PermaLink,
109
+ Vo as PermaLink,
108
110
  C as Permission,
109
- Vo as Radio,
110
- Wo as RadioList,
111
- qo as ResultError,
111
+ jo as Radio,
112
+ qo as RadioList,
113
+ Go as ResultError,
112
114
  oo as Row,
113
- Go as ScrollContainer,
114
- Qo as Select,
115
- Yo as Sidebar,
116
- oe as StatusTag,
117
- re as StatusTypography,
118
- ae as Stepper,
119
- le as Switch,
120
- pe as Tab,
121
- xe as Table,
122
- ue as TableHeader,
123
- ne as Textarea,
124
- Ce as Tooltip,
125
- Te as TypographyText,
126
- Ie as ValidationError,
127
- so as createConnectedService,
115
+ Ko as ScrollContainer,
116
+ Yo as Select,
117
+ _o as Sidebar,
118
+ re as StatusTag,
119
+ ae as StatusTypography,
120
+ le as Stepper,
121
+ pe as Switch,
122
+ xe as Tab,
123
+ ue as Table,
124
+ ne as TableHeader,
125
+ Ce as Textarea,
126
+ Te as Tooltip,
127
+ Se as TypographyText,
128
+ Pe as ValidationError,
129
+ io as createConnectedService,
128
130
  d as getAuth
129
131
  };
package/dist/index.d.mts CHANGED
@@ -597,6 +597,14 @@ export { i18n }
597
597
 
598
598
  export declare const Icon: (props: IconProps) => JSX.Element;
599
599
 
600
+ export declare const IconBox: ({ icon, onClick, type }: IconBoxProps) => JSX_2.Element;
601
+
602
+ export declare type IconBoxProps = {
603
+ icon: Icons;
604
+ onClick?: () => void;
605
+ type?: "primary" | "secondary";
606
+ };
607
+
600
608
  export declare type IconProps = {
601
609
  id?: string;
602
610
  name: IconsId;
package/dist/index.d.ts CHANGED
@@ -597,6 +597,14 @@ export { i18n }
597
597
 
598
598
  export declare const Icon: (props: IconProps) => JSX.Element;
599
599
 
600
+ export declare const IconBox: ({ icon, onClick, type }: IconBoxProps) => JSX_2.Element;
601
+
602
+ export declare type IconBoxProps = {
603
+ icon: Icons;
604
+ onClick?: () => void;
605
+ type?: "primary" | "secondary";
606
+ };
607
+
600
608
  export declare type IconProps = {
601
609
  id?: string;
602
610
  name: IconsId;