@dktunited-techoff/techoff-suite-ui 1.3.0 → 1.4.0
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/esm/assets/fonts/Montserrat-Medium.ttf +0 -0
- package/esm/assets/fonts/Roboto-Light.ttf +0 -0
- package/esm/components/TsButton/TsButton.css +91 -0
- package/esm/components/TsButton/TsButton.d.ts +5 -0
- package/esm/components/TsButton/TsButton.js +17 -0
- package/esm/components/TsButton/TsButton.js.map +1 -0
- package/esm/components/TsButton/TsButton.types.d.ts +9 -0
- package/esm/components/TsButton/TsButton.types.js +2 -0
- package/esm/components/TsButton/TsButton.types.js.map +1 -0
- package/esm/components/TsButton/__stories__/TsButton.stories.mdx +74 -0
- package/esm/components/TsIcon/TsIcon.css +26 -0
- package/esm/components/TsIcon/TsIcon.d.ts +4 -0
- package/esm/components/TsIcon/TsIcon.js +12 -0
- package/esm/components/TsIcon/TsIcon.js.map +1 -0
- package/esm/components/TsIcon/TsIcon.types.d.ts +4 -0
- package/esm/components/TsIcon/TsIcon.types.js +2 -0
- package/esm/components/TsIcon/TsIcon.types.js.map +1 -0
- package/esm/components/TsIcon/__stories__/TsIcon.stories.mdx +89 -0
- package/esm/components/TsIcon/icons/add-circle.svg +1 -0
- package/esm/components/TsIcon/icons/add.svg +1 -0
- package/esm/components/TsIcon/icons/alert-circle-filled.svg +1 -0
- package/esm/components/TsIcon/icons/alert-circle.svg +1 -0
- package/esm/components/TsIcon/icons/alert-triangle-filled.svg +1 -0
- package/esm/components/TsIcon/icons/alert-triangle.svg +1 -0
- package/esm/components/TsIcon/icons/arrow-diagonal-collapse.svg +1 -0
- package/esm/components/TsIcon/icons/arrow-diagonal-expand.svg +1 -0
- package/esm/components/TsIcon/icons/arrow-down.svg +1 -0
- package/esm/components/TsIcon/icons/arrow-go-back.svg +1 -0
- package/esm/components/TsIcon/icons/arrow-left-right.svg +1 -0
- package/esm/components/TsIcon/icons/arrow-left.svg +1 -0
- package/esm/components/TsIcon/icons/arrow-right.svg +1 -0
- package/esm/components/TsIcon/icons/arrow-up-down.svg +1 -0
- package/esm/components/TsIcon/icons/arrow-up.svg +1 -0
- package/esm/components/TsIcon/icons/award.svg +1 -0
- package/esm/components/TsIcon/icons/check-circle-filled.svg +1 -0
- package/esm/components/TsIcon/icons/check-circle-timer.svg +7 -0
- package/esm/components/TsIcon/icons/check-circle.svg +1 -0
- package/esm/components/TsIcon/icons/check-square-filled.svg +1 -0
- package/esm/components/TsIcon/icons/check-square.svg +1 -0
- package/esm/components/TsIcon/icons/check.svg +1 -0
- package/esm/components/TsIcon/icons/chevron-down.svg +1 -0
- package/esm/components/TsIcon/icons/chevron-left.svg +1 -0
- package/esm/components/TsIcon/icons/chevron-right.svg +1 -0
- package/esm/components/TsIcon/icons/chevron-up.svg +1 -0
- package/esm/components/TsIcon/icons/circle.svg +1 -0
- package/esm/components/TsIcon/icons/close-circle.svg +1 -0
- package/esm/components/TsIcon/icons/close.svg +1 -0
- package/esm/components/TsIcon/icons/currency-euro.svg +1 -0
- package/esm/components/TsIcon/icons/download.svg +1 -0
- package/esm/components/TsIcon/icons/edit.svg +1 -0
- package/esm/components/TsIcon/icons/external-link.svg +1 -0
- package/esm/components/TsIcon/icons/filter-off.svg +1 -0
- package/esm/components/TsIcon/icons/filter.svg +1 -0
- package/esm/components/TsIcon/icons/flashlight-off.svg +1 -0
- package/esm/components/TsIcon/icons/flashlight.svg +1 -0
- package/esm/components/TsIcon/icons/header-bikestudio.svg +32 -0
- package/esm/components/TsIcon/icons/header-nsc-helmet.svg +32 -0
- package/esm/components/TsIcon/icons/header-opticost.svg +32 -0
- package/esm/components/TsIcon/icons/header-repairability.svg +32 -0
- package/esm/components/TsIcon/icons/heart-filled.svg +1 -0
- package/esm/components/TsIcon/icons/heart.svg +1 -0
- package/esm/components/TsIcon/icons/history.svg +1 -0
- package/esm/components/TsIcon/icons/home.svg +1 -0
- package/esm/components/TsIcon/icons/index.d.ts +3 -0
- package/esm/components/TsIcon/icons/index.js +59 -0
- package/esm/components/TsIcon/icons/index.js.map +1 -0
- package/esm/components/TsIcon/icons/index.ts +58 -0
- package/esm/components/TsIcon/icons/link.svg +1 -0
- package/esm/components/TsIcon/icons/list-settings.svg +1 -0
- package/esm/components/TsIcon/icons/lock.svg +1 -0
- package/esm/components/TsIcon/icons/loop-right.svg +1 -0
- package/esm/components/TsIcon/icons/question-circle.svg +1 -0
- package/esm/components/TsIcon/icons/save.svg +1 -0
- package/esm/components/TsIcon/icons/search.svg +1 -0
- package/esm/components/TsIcon/icons/seedling-circle.svg +12 -0
- package/esm/components/TsIcon/icons/square.svg +1 -0
- package/esm/components/TsIcon/icons/tools.svg +1 -0
- package/esm/components/TsIcon/icons/user.svg +1 -0
- package/esm/components/TsInput/TsInput/TsInput.css +43 -0
- package/esm/components/TsInput/TsInput/TsInput.d.ts +4 -0
- package/esm/components/TsInput/TsInput/TsInput.js +12 -0
- package/esm/components/TsInput/TsInput/TsInput.js.map +1 -0
- package/esm/components/TsInput/TsInput/TsInput.tsx +19 -0
- package/esm/components/TsInput/TsInput/TsInput.types.d.ts +5 -0
- package/esm/components/TsInput/TsInput/TsInput.types.js +2 -0
- package/esm/components/TsInput/TsInput/TsInput.types.js.map +1 -0
- package/esm/components/TsInput/TsInput/TsInput.types.tsx +6 -0
- package/esm/components/TsInput/TsInput/__stories__/TsInput.stories.mdx +34 -0
- package/esm/components/TsLoader/TsLoader.css +42 -0
- package/esm/components/TsLoader/TsLoader.d.ts +4 -0
- package/esm/components/TsLoader/TsLoader.js +6 -0
- package/esm/components/TsLoader/TsLoader.js.map +1 -0
- package/esm/components/TsLoader/TsLoader.types.d.ts +3 -0
- package/esm/components/TsLoader/TsLoader.types.js +2 -0
- package/esm/components/TsLoader/TsLoader.types.js.map +1 -0
- package/esm/components/TsLoader/__stories__/TsLoader.stories.mdx +30 -0
- package/esm/hooks/use-click-outside.d.ts +2 -0
- package/esm/hooks/use-click-outside.js +14 -0
- package/esm/hooks/use-click-outside.js.map +1 -0
- package/esm/index.d.ts +6 -0
- package/esm/index.js +7 -0
- package/esm/index.js.map +1 -0
- package/esm/layouts/TsHeader/TsHeader.css +186 -0
- package/esm/layouts/TsHeader/TsHeader.d.ts +4 -0
- package/esm/layouts/TsHeader/TsHeader.js +13 -0
- package/esm/layouts/TsHeader/TsHeader.js.map +1 -0
- package/esm/layouts/TsHeader/TsHeader.types.d.ts +23 -0
- package/esm/layouts/TsHeader/TsHeader.types.js +2 -0
- package/esm/layouts/TsHeader/TsHeader.types.js.map +1 -0
- package/esm/layouts/TsHeader/TsHeaderProfile.d.ts +5 -0
- package/esm/layouts/TsHeader/TsHeaderProfile.js +38 -0
- package/esm/layouts/TsHeader/TsHeaderProfile.js.map +1 -0
- package/esm/layouts/TsHeader/TsHeaderSearch.d.ts +3 -0
- package/esm/layouts/TsHeader/TsHeaderSearch.js +58 -0
- package/esm/layouts/TsHeader/TsHeaderSearch.js.map +1 -0
- package/esm/layouts/TsHeader/__stories__/TsHeader.stories.mdx +71 -0
- package/esm/layouts/TsNavigation/TsNavigation.css +74 -0
- package/esm/layouts/TsNavigation/TsNavigation.d.ts +7 -0
- package/esm/layouts/TsNavigation/TsNavigation.js +29 -0
- package/esm/layouts/TsNavigation/TsNavigation.js.map +1 -0
- package/esm/layouts/TsNavigation/TsNavigation.types.d.ts +10 -0
- package/esm/layouts/TsNavigation/TsNavigation.types.js +2 -0
- package/esm/layouts/TsNavigation/TsNavigation.types.js.map +1 -0
- package/esm/layouts/TsNavigation/__stories__/TsNavigation.stories.mdx +51 -0
- package/esm/utils/string.utils.d.ts +1 -0
- package/esm/utils/string.utils.js +2 -0
- package/esm/utils/string.utils.js.map +1 -0
- package/lib/assets/fonts/Montserrat-Medium.ttf +0 -0
- package/lib/assets/fonts/Roboto-Light.ttf +0 -0
- package/lib/components/TsButton/TsButton.css +91 -0
- package/lib/components/TsButton/TsButton.d.ts +5 -0
- package/lib/components/TsButton/TsButton.js +21 -0
- package/lib/components/TsButton/TsButton.js.map +1 -0
- package/lib/components/TsButton/TsButton.types.d.ts +9 -0
- package/lib/components/TsButton/TsButton.types.js +3 -0
- package/lib/components/TsButton/TsButton.types.js.map +1 -0
- package/lib/components/TsButton/__stories__/TsButton.stories.mdx +74 -0
- package/lib/components/TsIcon/TsIcon.css +26 -0
- package/lib/components/TsIcon/TsIcon.d.ts +4 -0
- package/lib/components/TsIcon/TsIcon.js +16 -0
- package/lib/components/TsIcon/TsIcon.js.map +1 -0
- package/lib/components/TsIcon/TsIcon.types.d.ts +4 -0
- package/lib/components/TsIcon/TsIcon.types.js +3 -0
- package/lib/components/TsIcon/TsIcon.types.js.map +1 -0
- package/lib/components/TsIcon/__stories__/TsIcon.stories.mdx +89 -0
- package/lib/components/TsIcon/icons/add-circle.svg +1 -0
- package/lib/components/TsIcon/icons/add.svg +1 -0
- package/lib/components/TsIcon/icons/alert-circle-filled.svg +1 -0
- package/lib/components/TsIcon/icons/alert-circle.svg +1 -0
- package/lib/components/TsIcon/icons/alert-triangle-filled.svg +1 -0
- package/lib/components/TsIcon/icons/alert-triangle.svg +1 -0
- package/lib/components/TsIcon/icons/arrow-diagonal-collapse.svg +1 -0
- package/lib/components/TsIcon/icons/arrow-diagonal-expand.svg +1 -0
- package/lib/components/TsIcon/icons/arrow-down.svg +1 -0
- package/lib/components/TsIcon/icons/arrow-go-back.svg +1 -0
- package/lib/components/TsIcon/icons/arrow-left-right.svg +1 -0
- package/lib/components/TsIcon/icons/arrow-left.svg +1 -0
- package/lib/components/TsIcon/icons/arrow-right.svg +1 -0
- package/lib/components/TsIcon/icons/arrow-up-down.svg +1 -0
- package/lib/components/TsIcon/icons/arrow-up.svg +1 -0
- package/lib/components/TsIcon/icons/award.svg +1 -0
- package/lib/components/TsIcon/icons/check-circle-filled.svg +1 -0
- package/lib/components/TsIcon/icons/check-circle-timer.svg +7 -0
- package/lib/components/TsIcon/icons/check-circle.svg +1 -0
- package/lib/components/TsIcon/icons/check-square-filled.svg +1 -0
- package/lib/components/TsIcon/icons/check-square.svg +1 -0
- package/lib/components/TsIcon/icons/check.svg +1 -0
- package/lib/components/TsIcon/icons/chevron-down.svg +1 -0
- package/lib/components/TsIcon/icons/chevron-left.svg +1 -0
- package/lib/components/TsIcon/icons/chevron-right.svg +1 -0
- package/lib/components/TsIcon/icons/chevron-up.svg +1 -0
- package/lib/components/TsIcon/icons/circle.svg +1 -0
- package/lib/components/TsIcon/icons/close-circle.svg +1 -0
- package/lib/components/TsIcon/icons/close.svg +1 -0
- package/lib/components/TsIcon/icons/currency-euro.svg +1 -0
- package/lib/components/TsIcon/icons/download.svg +1 -0
- package/lib/components/TsIcon/icons/edit.svg +1 -0
- package/lib/components/TsIcon/icons/external-link.svg +1 -0
- package/lib/components/TsIcon/icons/filter-off.svg +1 -0
- package/lib/components/TsIcon/icons/filter.svg +1 -0
- package/lib/components/TsIcon/icons/flashlight-off.svg +1 -0
- package/lib/components/TsIcon/icons/flashlight.svg +1 -0
- package/lib/components/TsIcon/icons/header-bikestudio.svg +32 -0
- package/lib/components/TsIcon/icons/header-nsc-helmet.svg +32 -0
- package/lib/components/TsIcon/icons/header-opticost.svg +32 -0
- package/lib/components/TsIcon/icons/header-repairability.svg +32 -0
- package/lib/components/TsIcon/icons/heart-filled.svg +1 -0
- package/lib/components/TsIcon/icons/heart.svg +1 -0
- package/lib/components/TsIcon/icons/history.svg +1 -0
- package/lib/components/TsIcon/icons/home.svg +1 -0
- package/lib/components/TsIcon/icons/index.d.ts +3 -0
- package/lib/components/TsIcon/icons/index.js +62 -0
- package/lib/components/TsIcon/icons/index.js.map +1 -0
- package/lib/components/TsIcon/icons/index.ts +58 -0
- package/lib/components/TsIcon/icons/link.svg +1 -0
- package/lib/components/TsIcon/icons/list-settings.svg +1 -0
- package/lib/components/TsIcon/icons/lock.svg +1 -0
- package/lib/components/TsIcon/icons/loop-right.svg +1 -0
- package/lib/components/TsIcon/icons/question-circle.svg +1 -0
- package/lib/components/TsIcon/icons/save.svg +1 -0
- package/lib/components/TsIcon/icons/search.svg +1 -0
- package/lib/components/TsIcon/icons/seedling-circle.svg +12 -0
- package/lib/components/TsIcon/icons/square.svg +1 -0
- package/lib/components/TsIcon/icons/tools.svg +1 -0
- package/lib/components/TsIcon/icons/user.svg +1 -0
- package/lib/components/TsInput/TsInput/TsInput.css +43 -0
- package/lib/components/TsInput/TsInput/TsInput.d.ts +4 -0
- package/lib/components/TsInput/TsInput/TsInput.js +16 -0
- package/lib/components/TsInput/TsInput/TsInput.js.map +1 -0
- package/lib/components/TsInput/TsInput/TsInput.tsx +19 -0
- package/lib/components/TsInput/TsInput/TsInput.types.d.ts +5 -0
- package/lib/components/TsInput/TsInput/TsInput.types.js +3 -0
- package/lib/components/TsInput/TsInput/TsInput.types.js.map +1 -0
- package/lib/components/TsInput/TsInput/TsInput.types.tsx +6 -0
- package/lib/components/TsInput/TsInput/__stories__/TsInput.stories.mdx +34 -0
- package/lib/components/TsLoader/TsLoader.css +42 -0
- package/lib/components/TsLoader/TsLoader.d.ts +4 -0
- package/lib/components/TsLoader/TsLoader.js +10 -0
- package/lib/components/TsLoader/TsLoader.js.map +1 -0
- package/lib/components/TsLoader/TsLoader.types.d.ts +3 -0
- package/lib/components/TsLoader/TsLoader.types.js +3 -0
- package/lib/components/TsLoader/TsLoader.types.js.map +1 -0
- package/lib/components/TsLoader/__stories__/TsLoader.stories.mdx +30 -0
- package/lib/hooks/use-click-outside.d.ts +2 -0
- package/lib/hooks/use-click-outside.js +18 -0
- package/lib/hooks/use-click-outside.js.map +1 -0
- package/lib/index.d.ts +6 -0
- package/lib/index.js +23 -0
- package/lib/index.js.map +1 -0
- package/lib/layouts/TsHeader/TsHeader.css +186 -0
- package/lib/layouts/TsHeader/TsHeader.d.ts +4 -0
- package/lib/layouts/TsHeader/TsHeader.js +17 -0
- package/lib/layouts/TsHeader/TsHeader.js.map +1 -0
- package/lib/layouts/TsHeader/TsHeader.types.d.ts +23 -0
- package/lib/layouts/TsHeader/TsHeader.types.js +3 -0
- package/lib/layouts/TsHeader/TsHeader.types.js.map +1 -0
- package/lib/layouts/TsHeader/TsHeaderProfile.d.ts +5 -0
- package/lib/layouts/TsHeader/TsHeaderProfile.js +43 -0
- package/lib/layouts/TsHeader/TsHeaderProfile.js.map +1 -0
- package/lib/layouts/TsHeader/TsHeaderSearch.d.ts +3 -0
- package/lib/layouts/TsHeader/TsHeaderSearch.js +62 -0
- package/lib/layouts/TsHeader/TsHeaderSearch.js.map +1 -0
- package/lib/layouts/TsHeader/__stories__/TsHeader.stories.mdx +71 -0
- package/lib/layouts/TsNavigation/TsNavigation.css +74 -0
- package/lib/layouts/TsNavigation/TsNavigation.d.ts +7 -0
- package/lib/layouts/TsNavigation/TsNavigation.js +35 -0
- package/lib/layouts/TsNavigation/TsNavigation.js.map +1 -0
- package/lib/layouts/TsNavigation/TsNavigation.types.d.ts +10 -0
- package/lib/layouts/TsNavigation/TsNavigation.types.js +3 -0
- package/lib/layouts/TsNavigation/TsNavigation.types.js.map +1 -0
- package/lib/layouts/TsNavigation/__stories__/TsNavigation.stories.mdx +51 -0
- package/lib/utils/string.utils.d.ts +1 -0
- package/lib/utils/string.utils.js +6 -0
- package/lib/utils/string.utils.js.map +1 -0
- package/package.json +1 -1
- package/src/components/TsInput/TsInput/TsInput.css +43 -0
- package/src/components/TsInput/TsInput/TsInput.tsx +19 -0
- package/src/components/TsInput/TsInput/TsInput.types.tsx +6 -0
- package/src/components/TsInput/TsInput/__stories__/TsInput.stories.mdx +34 -0
- package/src/layouts/TsHeader/TsHeaderSearch.tsx +1 -2
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
.ts-navigation {
|
|
2
|
+
display: flex;
|
|
3
|
+
align-items: center;
|
|
4
|
+
height: 32px;
|
|
5
|
+
padding: 0 24px;
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
/* ############ */
|
|
9
|
+
/* BREADCRUMB */
|
|
10
|
+
.ts-breadcrumb {
|
|
11
|
+
display: flex;
|
|
12
|
+
align-items: center;
|
|
13
|
+
padding-right: 20px;
|
|
14
|
+
}
|
|
15
|
+
.ts-breadcrumb-container {
|
|
16
|
+
display: flex;
|
|
17
|
+
align-items: center;
|
|
18
|
+
}
|
|
19
|
+
.ts-breadcrumb-chevron {
|
|
20
|
+
padding: 0 8px;
|
|
21
|
+
color: #3643ba;
|
|
22
|
+
}
|
|
23
|
+
.ts-breadcrumb-item {
|
|
24
|
+
display: flex;
|
|
25
|
+
align-items: center;
|
|
26
|
+
height: 32px;
|
|
27
|
+
border-radius: 9999px;
|
|
28
|
+
color: #3643ba;
|
|
29
|
+
}
|
|
30
|
+
.ts-breadcrumb-item--highlight {
|
|
31
|
+
padding: 0 20px;
|
|
32
|
+
box-shadow: 0px 6px 6px 0px #00537d1a;
|
|
33
|
+
background: linear-gradient(270deg, #3643ba 0%, rgba(54, 67, 186, 0.6) 100%);
|
|
34
|
+
color: #ffffff;
|
|
35
|
+
}
|
|
36
|
+
.ts-breadcrumb-item--link {
|
|
37
|
+
cursor: pointer;
|
|
38
|
+
}
|
|
39
|
+
.ts-breadcrumb-item--link:hover {
|
|
40
|
+
text-decoration: underline;
|
|
41
|
+
}
|
|
42
|
+
.ts-breadcrumb-item--icon {
|
|
43
|
+
padding-right: 8px;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
/* ######### */
|
|
47
|
+
/* DIVIDER */
|
|
48
|
+
.ts-navigation-divider {
|
|
49
|
+
flex: 1;
|
|
50
|
+
height: 1px;
|
|
51
|
+
margin: 4px 0;
|
|
52
|
+
background: #ebecf7;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
/* ######### */
|
|
56
|
+
/* ACTIONS */
|
|
57
|
+
.ts-navigation-actions {
|
|
58
|
+
/* flex items-center [&>*]:ml-4 */
|
|
59
|
+
display: flex;
|
|
60
|
+
align-items: center;
|
|
61
|
+
}
|
|
62
|
+
.ts-navigation-actions > * {
|
|
63
|
+
margin-left: 16px;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
/* ######### */
|
|
67
|
+
/* GLOBALS */
|
|
68
|
+
* {
|
|
69
|
+
font-size: 14px;
|
|
70
|
+
outline: none;
|
|
71
|
+
box-sizing: border-box;
|
|
72
|
+
font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans',
|
|
73
|
+
'Helvetica Neue', sans-serif;
|
|
74
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { PropsWithChildren } from 'react';
|
|
3
|
+
import { TsNavigationBreadcrumbItemProps, TsNavigationProps } from './TsNavigation.types';
|
|
4
|
+
import './TsNavigation.css';
|
|
5
|
+
export declare const TsNavigationBreadcrumbDivider: () => React.JSX.Element;
|
|
6
|
+
export declare const TsNavigationBreadcrumbItem: ({ children, icon, highlight, onClick, }: PropsWithChildren<TsNavigationBreadcrumbItemProps>) => React.JSX.Element;
|
|
7
|
+
export declare const TsNavigation: ({ actions, breadcrumbs }: TsNavigationProps) => React.JSX.Element;
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.TsNavigation = exports.TsNavigationBreadcrumbItem = exports.TsNavigationBreadcrumbDivider = void 0;
|
|
4
|
+
const React = require("react");
|
|
5
|
+
const TsIcon_1 = require("../../components/TsIcon/TsIcon");
|
|
6
|
+
require("./TsNavigation.css");
|
|
7
|
+
const TsNavigationBreadcrumbDivider = () => {
|
|
8
|
+
// #########
|
|
9
|
+
// Rendering
|
|
10
|
+
return (React.createElement("div", { className: "ts-breadcrumb-chevron" },
|
|
11
|
+
React.createElement(TsIcon_1.TsIcon, { name: "chevron-right" })));
|
|
12
|
+
};
|
|
13
|
+
exports.TsNavigationBreadcrumbDivider = TsNavigationBreadcrumbDivider;
|
|
14
|
+
const TsNavigationBreadcrumbItem = ({ children, icon, highlight, onClick, }) => {
|
|
15
|
+
// #########
|
|
16
|
+
// Rendering
|
|
17
|
+
return (React.createElement("div", { className: `
|
|
18
|
+
ts-breadcrumb-item
|
|
19
|
+
${highlight ? 'ts-breadcrumb-item--highlight' : ''} ${onClick ? 'ts-breadcrumb-item--link' : ''}
|
|
20
|
+
`, onClick: onClick },
|
|
21
|
+
icon && (React.createElement("div", { className: "ts-breadcrumb-item--icon" },
|
|
22
|
+
React.createElement(TsIcon_1.TsIcon, { name: icon, size: "16" }))),
|
|
23
|
+
children));
|
|
24
|
+
};
|
|
25
|
+
exports.TsNavigationBreadcrumbItem = TsNavigationBreadcrumbItem;
|
|
26
|
+
const TsNavigation = ({ actions, breadcrumbs }) => {
|
|
27
|
+
// #########
|
|
28
|
+
// Rendering
|
|
29
|
+
return (React.createElement("div", { className: "ts-navigation" },
|
|
30
|
+
React.createElement("div", { className: "ts-breadcrumb" }, breadcrumbs),
|
|
31
|
+
React.createElement("div", { className: "ts-navigation-divider" }),
|
|
32
|
+
React.createElement("div", { className: "ts-navigation-actions" }, actions)));
|
|
33
|
+
};
|
|
34
|
+
exports.TsNavigation = TsNavigation;
|
|
35
|
+
//# sourceMappingURL=TsNavigation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TsNavigation.js","sourceRoot":"","sources":["../../../src/layouts/TsNavigation/TsNavigation.tsx"],"names":[],"mappings":";;;AAAA,+BAA+B;AAE/B,2DAAwD;AAExD,8BAA4B;AAErB,MAAM,6BAA6B,GAAG,GAAG,EAAE;IAChD,YAAY;IACZ,YAAY;IACZ,OAAO,CACL,6BAAK,SAAS,EAAC,uBAAuB;QACpC,oBAAC,eAAM,IAAC,IAAI,EAAC,eAAe,GAAG,CAC3B,CACP,CAAC;AACJ,CAAC,CAAC;AARW,QAAA,6BAA6B,iCAQxC;AAEK,MAAM,0BAA0B,GAAG,CAAC,EACzC,QAAQ,EACR,IAAI,EACJ,SAAS,EACT,OAAO,GAC4C,EAAE,EAAE;IACvD,YAAY;IACZ,YAAY;IACZ,OAAO,CACL,6BACE,SAAS,EAAE;;UAEP,SAAS,CAAC,CAAC,CAAC,+BAA+B,CAAC,CAAC,CAAC,EAAE,IAAI,OAAO,CAAC,CAAC,CAAC,0BAA0B,CAAC,CAAC,CAAC,EAAE;OAChG,EACD,OAAO,EAAE,OAAO;QAEf,IAAI,IAAI,CACP,6BAAK,SAAS,EAAC,0BAA0B;YACvC,oBAAC,eAAM,IAAC,IAAI,EAAE,IAAI,EAAE,IAAI,EAAC,IAAI,GAAG,CAC5B,CACP;QAEA,QAAQ,CACL,CACP,CAAC;AACJ,CAAC,CAAC;AAzBW,QAAA,0BAA0B,8BAyBrC;AAEK,MAAM,YAAY,GAAG,CAAC,EAAE,OAAO,EAAE,WAAW,EAAqB,EAAE,EAAE;IAC1E,YAAY;IACZ,YAAY;IACZ,OAAO,CACL,6BAAK,SAAS,EAAC,eAAe;QAC5B,6BAAK,SAAS,EAAC,eAAe,IAAE,WAAW,CAAO;QAClD,6BAAK,SAAS,EAAC,uBAAuB,GAAG;QACzC,6BAAK,SAAS,EAAC,uBAAuB,IAAE,OAAO,CAAO,CAClD,CACP,CAAC;AACJ,CAAC,CAAC;AAVW,QAAA,YAAY,gBAUvB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TsNavigation.types.js","sourceRoot":"","sources":["../../../src/layouts/TsNavigation/TsNavigation.types.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { ArgsTable, Canvas, Meta, Story } from '@storybook/blocks';
|
|
3
|
+
import { TsNavigation, TsNavigationBreadcrumbItem, TsNavigationBreadcrumbDivider } from '../TsNavigation';
|
|
4
|
+
import { TsButton } from '../../../components/TsButton/TsButton';
|
|
5
|
+
import { icons } from '../../../components/TsIcon/icons';
|
|
6
|
+
|
|
7
|
+
<Meta title="Layouts/Navigation" />
|
|
8
|
+
|
|
9
|
+
# Navigation
|
|
10
|
+
|
|
11
|
+
Breadcrumbs are an important navigation component that shows content hierarchy. They allow users to be aware of their current location in the hierarchical structure of the application. Breadcrumbs enable users to quickly move up to a parent level. Moreover this navigation component allows user to make some actions.
|
|
12
|
+
|
|
13
|
+
## Overview
|
|
14
|
+
|
|
15
|
+
<Canvas>
|
|
16
|
+
<Story
|
|
17
|
+
name="Overview"
|
|
18
|
+
args={{
|
|
19
|
+
actions: (
|
|
20
|
+
<>
|
|
21
|
+
<TsButton icon="check" onClick={() => {}}>
|
|
22
|
+
Action 1
|
|
23
|
+
</TsButton>
|
|
24
|
+
<TsButton icon="add" onClick={() => {}}>
|
|
25
|
+
Action 2
|
|
26
|
+
</TsButton>
|
|
27
|
+
</>
|
|
28
|
+
),
|
|
29
|
+
breadcrumbs: (
|
|
30
|
+
<>
|
|
31
|
+
<TsNavigationBreadcrumbItem icon="home" onClick={() => {}}>
|
|
32
|
+
Home
|
|
33
|
+
</TsNavigationBreadcrumbItem>
|
|
34
|
+
<TsNavigationBreadcrumbDivider />
|
|
35
|
+
<TsNavigationBreadcrumbItem onClick={() => {}}>Menu Item 1</TsNavigationBreadcrumbItem>
|
|
36
|
+
<TsNavigationBreadcrumbDivider />
|
|
37
|
+
<TsNavigationBreadcrumbItem highlight>Menu Item 2</TsNavigationBreadcrumbItem>
|
|
38
|
+
</>
|
|
39
|
+
)
|
|
40
|
+
}}
|
|
41
|
+
|
|
42
|
+
>
|
|
43
|
+
|
|
44
|
+
{args => <TsNavigation {...args} />}
|
|
45
|
+
|
|
46
|
+
</Story>
|
|
47
|
+
</Canvas>
|
|
48
|
+
|
|
49
|
+
## Props
|
|
50
|
+
|
|
51
|
+
<ArgsTable story="Overview" of={TsNavigation} />
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const capitalize: (str: string) => string;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.capitalize = void 0;
|
|
4
|
+
const capitalize = (str) => str.charAt(0).toUpperCase() + str.slice(1).toLowerCase();
|
|
5
|
+
exports.capitalize = capitalize;
|
|
6
|
+
//# sourceMappingURL=string.utils.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"string.utils.js","sourceRoot":"","sources":["../../src/utils/string.utils.ts"],"names":[],"mappings":";;;AAAO,MAAM,UAAU,GAAG,CAAC,GAAW,EAAE,EAAE,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,WAAW,EAAE,GAAG,GAAG,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,WAAW,EAAE,CAAC;AAAvF,QAAA,UAAU,cAA6E"}
|
package/package.json
CHANGED
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
.ts-input {
|
|
2
|
+
position: relative;
|
|
3
|
+
width: 100%;
|
|
4
|
+
height: 32px;
|
|
5
|
+
}
|
|
6
|
+
input {
|
|
7
|
+
width: 100%;
|
|
8
|
+
height: 100%;
|
|
9
|
+
padding: 0 10px;
|
|
10
|
+
border: 1px solid #949494;
|
|
11
|
+
font-weight: 600;
|
|
12
|
+
}
|
|
13
|
+
input::placeholder {
|
|
14
|
+
font-weight: 400;
|
|
15
|
+
}
|
|
16
|
+
input:focus {
|
|
17
|
+
border: 1.5px solid #3643ba;
|
|
18
|
+
}
|
|
19
|
+
.ts-input--padding-1 input {
|
|
20
|
+
padding: 0 30px 0 10px;
|
|
21
|
+
}
|
|
22
|
+
.ts-input-icon {
|
|
23
|
+
position: absolute;
|
|
24
|
+
top: 0;
|
|
25
|
+
right: 0;
|
|
26
|
+
display: flex;
|
|
27
|
+
align-items: center;
|
|
28
|
+
justify-content: center;
|
|
29
|
+
width: 32px;
|
|
30
|
+
min-width: 32px;
|
|
31
|
+
height: 32px;
|
|
32
|
+
color: #949494;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
/* ######### */
|
|
36
|
+
/* GLOBALS */
|
|
37
|
+
* {
|
|
38
|
+
font-size: 14px;
|
|
39
|
+
outline: none;
|
|
40
|
+
box-sizing: border-box;
|
|
41
|
+
font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans',
|
|
42
|
+
'Helvetica Neue', sans-serif;
|
|
43
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { TsIcon } from '../../TsIcon/TsIcon';
|
|
3
|
+
import { TsInputProps } from './TsInput.types';
|
|
4
|
+
import './TsInput.css';
|
|
5
|
+
|
|
6
|
+
export const TsInput = ({ icon, value, onChange, ...props }: TsInputProps) => {
|
|
7
|
+
// #########
|
|
8
|
+
// Rendering
|
|
9
|
+
return (
|
|
10
|
+
<div className={`ts-input ${icon ? 'ts-input--padding-1' : ''}`}>
|
|
11
|
+
<input type="text" value={value} onChange={e => onChange(e.target.value)} {...props} />
|
|
12
|
+
{icon && (
|
|
13
|
+
<div className="ts-input-icon">
|
|
14
|
+
<TsIcon name={icon} size="16" />
|
|
15
|
+
</div>
|
|
16
|
+
)}
|
|
17
|
+
</div>
|
|
18
|
+
);
|
|
19
|
+
};
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { ArgsTable, Canvas, Meta, Story } from '@storybook/blocks';
|
|
3
|
+
import { TsInput } from '../TsInput';
|
|
4
|
+
import { icons } from '../../../TsIcon/icons';
|
|
5
|
+
|
|
6
|
+
<Meta title="Components/Input" />
|
|
7
|
+
|
|
8
|
+
export const inputArgTypes = {
|
|
9
|
+
icon: {
|
|
10
|
+
control: 'select',
|
|
11
|
+
options: Object.keys(icons),
|
|
12
|
+
description: 'Icon of the button.',
|
|
13
|
+
},
|
|
14
|
+
placeholder: {
|
|
15
|
+
control: 'text',
|
|
16
|
+
description: 'Placeholder of the button.',
|
|
17
|
+
},
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
# Input
|
|
21
|
+
|
|
22
|
+
Input allows the user to enter content and data when the expected user input is a single line of text.
|
|
23
|
+
|
|
24
|
+
## Overview
|
|
25
|
+
|
|
26
|
+
<Canvas>
|
|
27
|
+
<Story name="Overview" args={{ onChange: () => {} }} argTypes={inputArgTypes}>
|
|
28
|
+
{args => <TsInput {...args} />}
|
|
29
|
+
</Story>
|
|
30
|
+
</Canvas>
|
|
31
|
+
|
|
32
|
+
## Props
|
|
33
|
+
|
|
34
|
+
<ArgsTable story="Overview" of={TsInput} />
|
|
@@ -10,10 +10,9 @@ export const TsHeaderSearch = ({
|
|
|
10
10
|
getItemValue,
|
|
11
11
|
loadItems,
|
|
12
12
|
noDataLabel,
|
|
13
|
-
placeholder,
|
|
14
13
|
onChange,
|
|
15
14
|
}: TsHeaderSearchProps) => {
|
|
16
|
-
const [searchValue
|
|
15
|
+
const [searchValue] = useState<string>('');
|
|
17
16
|
const [items, setItems] = useState<any[]>([]);
|
|
18
17
|
const [isLoading, setIsLoading] = useState<boolean>(false);
|
|
19
18
|
const [showItems, setShowItems] = useState<boolean>(false);
|