@dilicorp/ui 0.2.30 → 0.2.31

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.
Files changed (90) hide show
  1. package/dist/atoms/icon.d.ts +1 -2
  2. package/dist/atoms/icon.js +3 -15
  3. package/dist/atoms/input-datepicker.d.ts +0 -1
  4. package/dist/atoms/input-datepicker.js +2 -2
  5. package/dist/atoms/pluxee-icon/base-icon.js +7 -1
  6. package/dist/atoms/pluxee-icon/icon-download.js +2 -2
  7. package/dist/atoms/pluxee-icon/pluxee-icon.d.ts +1 -8
  8. package/dist/atoms/pluxee-icon/pluxee-icon.js +3 -24
  9. package/dist/components/alert-template/alert-provider.js +1 -1
  10. package/dist/components/form-builder/components/button.d.ts +1 -1
  11. package/dist/components/form-builder/components/button.js +1 -2
  12. package/dist/components/form-builder/components/checkbox.d.ts +0 -1
  13. package/dist/components/form-builder/components/checkbox.js +3 -4
  14. package/dist/components/form-builder/components/input-currency.js +2 -15
  15. package/dist/components/form-builder/components/input-mask.js +2 -15
  16. package/dist/components/form-builder/components/input-prefix-suffix.js +2 -15
  17. package/dist/components/form-builder/components/input.d.ts +0 -1
  18. package/dist/components/form-builder/components/input.js +4 -6
  19. package/dist/components/form-builder/components/radio.d.ts +0 -1
  20. package/dist/components/form-builder/components/radio.js +3 -4
  21. package/dist/components/layout/authenticated-layout/authenticated-layout.d.ts +0 -4
  22. package/dist/components/layout/authenticated-layout/authenticated-layout.js +6 -6
  23. package/dist/components/layout/layout.d.ts +0 -4
  24. package/dist/components/page-create/page-create.d.ts +1 -1
  25. package/dist/components/page-create/page-create.js +1 -1
  26. package/dist/components/page-list/filters/filter-async-select.d.ts +25 -0
  27. package/dist/components/page-list/filters/filter-async-select.js +49 -0
  28. package/dist/components/page-list/filters/index.d.ts +1 -0
  29. package/dist/components/page-list/filters/index.js +1 -0
  30. package/dist/components/page-list/page-list.js +2 -6
  31. package/dist/components/side-navigation-bar/side-navigation-bar-item.d.ts +0 -1
  32. package/dist/components/side-navigation-bar/side-navigation-bar-item.js +13 -38
  33. package/dist/components/side-navigation-bar/side-navigation-bar.js +2 -2
  34. package/dist/css/style.min.css +2 -2
  35. package/dist/index.d.ts +2 -5
  36. package/dist/index.js +2 -5
  37. package/dist/molecules/table-column-management.js +4 -8
  38. package/dist/molecules/table.d.ts +2 -0
  39. package/dist/molecules/table.js +3 -3
  40. package/package.json +1 -1
  41. package/.vscode/extensions.json +0 -7
  42. package/.vscode/settings.json +0 -38
  43. package/dist/atoms/pluxee-icon/icon-card-slashed.d.ts +0 -6
  44. package/dist/atoms/pluxee-icon/icon-card-slashed.js +0 -12
  45. package/dist/atoms/pluxee-icon/icon-circle.d.ts +0 -6
  46. package/dist/atoms/pluxee-icon/icon-circle.js +0 -6
  47. package/dist/atoms/pluxee-icon/icon-clock.d.ts +0 -6
  48. package/dist/atoms/pluxee-icon/icon-clock.js +0 -7
  49. package/dist/atoms/pluxee-icon/icon-eye-closed-outline.d.ts +0 -6
  50. package/dist/atoms/pluxee-icon/icon-eye-closed-outline.js +0 -10
  51. package/dist/atoms/pluxee-icon/icon-identification.d.ts +0 -6
  52. package/dist/atoms/pluxee-icon/icon-identification.js +0 -10
  53. package/dist/atoms/pluxee-icon/icon-negotiation.d.ts +0 -6
  54. package/dist/atoms/pluxee-icon/icon-negotiation.js +0 -6
  55. package/dist/atoms/pluxee-icon/icon-play.d.ts +0 -6
  56. package/dist/atoms/pluxee-icon/icon-play.js +0 -6
  57. package/dist/atoms/pluxee-icon/icon-qrcode.d.ts +0 -6
  58. package/dist/atoms/pluxee-icon/icon-qrcode.js +0 -17
  59. package/dist/atoms/pluxee-icon/icon-update-limit.d.ts +0 -6
  60. package/dist/atoms/pluxee-icon/icon-update-limit.js +0 -8
  61. package/dist/atoms/pluxee-icon/icon-user-group.d.ts +0 -6
  62. package/dist/atoms/pluxee-icon/icon-user-group.js +0 -6
  63. package/dist/components/layout/pluxee-logo/pluxee-logo-card.d.ts +0 -8
  64. package/dist/components/layout/pluxee-logo/pluxee-logo-card.js +0 -14
  65. package/dist/molecules/card-summary/card-summary-body.d.ts +0 -12
  66. package/dist/molecules/card-summary/card-summary-body.js +0 -9
  67. package/dist/molecules/card-summary/card-summary-container.d.ts +0 -14
  68. package/dist/molecules/card-summary/card-summary-container.js +0 -19
  69. package/dist/molecules/card-summary/card-summary-footer.d.ts +0 -15
  70. package/dist/molecules/card-summary/card-summary-footer.js +0 -11
  71. package/dist/molecules/card-summary/card-summary-header.d.ts +0 -12
  72. package/dist/molecules/card-summary/card-summary-header.js +0 -11
  73. package/dist/molecules/card-summary/card-summary.d.ts +0 -40
  74. package/dist/molecules/card-summary/card-summary.js +0 -10
  75. package/dist/molecules/modal/modal.d.ts +0 -11
  76. package/dist/molecules/modal/modal.js +0 -15
  77. package/dist/molecules/panel/panel-container.d.ts +0 -12
  78. package/dist/molecules/panel/panel-container.js +0 -9
  79. package/dist/molecules/panel/panel-field.d.ts +0 -12
  80. package/dist/molecules/panel/panel-field.js +0 -12
  81. package/dist/molecules/panel/panel-group.d.ts +0 -14
  82. package/dist/molecules/panel/panel-group.js +0 -9
  83. package/dist/molecules/panel/panel.d.ts +0 -31
  84. package/dist/molecules/panel/panel.js +0 -8
  85. package/dist/molecules/player-video/modal-video.d.ts +0 -24
  86. package/dist/molecules/player-video/modal-video.js +0 -18
  87. package/dist/molecules/player-video/player-video.d.ts +0 -31
  88. package/dist/molecules/player-video/player-video.js +0 -8
  89. package/dist/molecules/player-video/thumb-video.d.ts +0 -12
  90. package/dist/molecules/player-video/thumb-video.js +0 -11
@@ -12,52 +12,27 @@ var __rest = (this && this.__rest) || function (s, e) {
12
12
  import React, { useState } from 'react';
13
13
  import { Icon } from '../../atoms/icon';
14
14
  import { Link } from '../../index';
15
- const InnerItem = ({ icon, iconSize = 'md', pluxee, label, dataLink }) => {
15
+ const InnerItem = ({ icon, pluxee, label, dataLink }) => {
16
16
  return (React.createElement(React.Fragment, null,
17
- icon && React.createElement(Icon, { title: label, icon: icon, pluxee: pluxee, size: iconSize }),
18
- React.createElement("span", { title: label, style: Object.assign({}, (iconSize === 'sm' && { fontSize: 12 })), className: "link-name", "data-link": `${dataLink ? 'link' : 'container'}` }, label)));
17
+ icon && React.createElement(Icon, { icon: icon, pluxee: pluxee }),
18
+ React.createElement("span", { className: "link-name", "data-link": `${dataLink ? 'link' : 'container'}` }, label)));
19
19
  };
20
20
  export const SideNavigationBarItem = (props) => {
21
21
  var _a;
22
- const [submenuOpen, setSubmenuOpen] = useState(false);
23
22
  const { className = '', items, index, pathname = '' } = props, attrs = __rest(props, ["className", "items", "index", "pathname"]);
24
- const sanitizedHref = ((attrs === null || attrs === void 0 ? void 0 : attrs.href) ? (_a = attrs === null || attrs === void 0 ? void 0 : attrs.href) === null || _a === void 0 ? void 0 : _a.split('?')[0] : '/').split('/')[1];
25
- const sanitizedPath = pathname === null || pathname === void 0 ? void 0 : pathname.split('/')[1];
26
- const isHomePage = ((attrs === null || attrs === void 0 ? void 0 : attrs.href) === '/' && pathname === '/');
27
- const isPathActive = sanitizedHref && (sanitizedPath === null || sanitizedPath === void 0 ? void 0 : sanitizedPath.includes(sanitizedHref));
28
- const activeClass = (isHomePage || isPathActive) ? ' active' : '';
29
- const itemclass = items && items.length > 0 ? ' submenu-li' : ' link-li';
30
- const submenuActive = items && items.some(item => {
31
- var _a, _b;
32
- const linkpath = ((item === null || item === void 0 ? void 0 : item.href) ? (_a = item === null || item === void 0 ? void 0 : item.href) === null || _a === void 0 ? void 0 : _a.split('?')[0] : '/').split('/').slice(-1)[0];
33
- return (_b = pathname === null || pathname === void 0 ? void 0 : pathname.split('/')) === null || _b === void 0 ? void 0 : _b.some(sub => sub === linkpath);
34
- })
35
- ? ' active'
36
- : '';
37
- const handleSubmenuClick = () => {
38
- const sidebar = document.querySelector('.sidebar');
39
- if (!sidebar.className.includes('active') && !sidebar.className.includes('mobile')) {
40
- const btn = document.querySelector('.btn-sidebar');
41
- btn === null || btn === void 0 ? void 0 : btn.click();
42
- setSubmenuOpen(true);
43
- return;
44
- }
45
- setSubmenuOpen(prev => !prev);
46
- };
47
- return (React.createElement("li", { className: `${className}${activeClass}${itemclass}${submenuActive}` }, items
23
+ const [active, setActive] = useState(false);
24
+ const sanitizedHref = (attrs === null || attrs === void 0 ? void 0 : attrs.href) ? (_a = attrs === null || attrs === void 0 ? void 0 : attrs.href) === null || _a === void 0 ? void 0 : _a.split('?')[0] : '';
25
+ const isHomePage = (sanitizedHref === '/' && pathname === '/');
26
+ const isPathActive = sanitizedHref && sanitizedHref !== '/' && pathname.includes(sanitizedHref);
27
+ const activeClass = isHomePage || isPathActive ? ' active' : '';
28
+ return (React.createElement("li", { className: `${className}${activeClass}` }, items
48
29
  ? React.createElement("div", { className: "sub-menu-container" },
49
- React.createElement("div", { onClick: handleSubmenuClick, className: `sub-menu${submenuOpen ? ' open' : ''}` },
30
+ React.createElement("div", { className: "sub-menu", onClick: () => setActive(prev => !prev) },
50
31
  React.createElement("div", null,
51
32
  React.createElement(InnerItem, Object.assign({}, props))),
52
- React.createElement(Icon, { pluxee: true, icon: "fa-chevron-down" })),
53
- items && React.createElement(React.Fragment, null,
54
- React.createElement("ul", { className: "sub-menu-list" }, items.map((item, i) => {
55
- var _a, _b;
56
- const lastpath = (_a = pathname === null || pathname === void 0 ? void 0 : pathname.split('/')) === null || _a === void 0 ? void 0 : _a.slice(-1)[0];
57
- const linkpath = ((item === null || item === void 0 ? void 0 : item.href) ? (_b = item === null || item === void 0 ? void 0 : item.href) === null || _b === void 0 ? void 0 : _b.split('?')[0] : '/').split('/').slice(-1)[0];
58
- const itemclass = lastpath === linkpath ? 'active' : '';
59
- return (React.createElement(SideNavigationBarItem, Object.assign({ key: `side-navigation-bar-item-${index}-${i}`, iconSize: "sm", pathname: pathname, className: itemclass }, Object.assign(Object.assign({}, item), { index: i }), { icon: "fa-circle", pluxee: true })));
60
- }))))
33
+ React.createElement(Icon, { icon: "fa-angle-down" })),
34
+ active && React.createElement("div", null,
35
+ React.createElement("ul", { className: "sub-menu-list" }, items.map((item, i) => (React.createElement(SideNavigationBarItem, Object.assign({ key: `side-navigation-bar-item-${index}-${i}` }, Object.assign(Object.assign({}, item), { index: i }))))))))
61
36
  : React.createElement(Link, Object.assign({}, attrs),
62
37
  React.createElement(InnerItem, Object.assign({}, props, { dataLink: true })))));
63
38
  };
@@ -7,11 +7,11 @@ import { useLocation } from 'react-router-dom';
7
7
  const STORAGE_NAME = 'SIDEBAR_ACTIVE';
8
8
  export const SideNavigationBar = memo((props) => {
9
9
  const { logout, items = [], active = true, menuLabel = 'Menu' } = props;
10
- const navlist = useRef(null);
11
- const { pathname, search } = useLocation();
12
10
  const activeStorage = storageHelper.get(STORAGE_NAME);
13
11
  const showActive = activeStorage ? activeStorage === '1' : active;
14
12
  storageHelper.set(STORAGE_NAME, showActive ? '1' : '0');
13
+ const navlist = useRef(null);
14
+ const { pathname, search } = useLocation();
15
15
  const uri = `${pathname}${search}`;
16
16
  useEffect(() => {
17
17
  const btnMobile = document.querySelector('.btn-sidebar-mobile');