@vitrosoftware/common-ui-ts 1.1.70 → 1.1.71

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,113 @@
1
+ .vitro-route-item {
2
+ display: flex;
3
+ width: 100%;
4
+ margin-top: 16px;
5
+ }
6
+
7
+ .vitro-route-item:nth-child(2) {
8
+ margin-top: 0;
9
+ }
10
+
11
+ .vitro-route-item-content {
12
+ width: 100%;
13
+ }
14
+
15
+ .vitro-button-collapse,
16
+ .vitro-button-expand,
17
+ .vitro-button-hide-comment,
18
+ .vitro-button-show-comment {
19
+ width: 24px;
20
+ height: 24px;
21
+ min-width: 24px;
22
+ background-position: center;
23
+ background-size: 100%;
24
+ border: none;
25
+ background-color: transparent;
26
+ }
27
+
28
+ .vitro-button-collapse,
29
+ .vitro-button-expand {
30
+ margin-right: 12px;
31
+ }
32
+
33
+ .vitro-button-collapse {
34
+ /* collapse-bottom.svg URL-encoder for SVG */
35
+ background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 25' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cg id='chevron-right' filter='url(%23filter0_dd_2119_119831)'%3E%3Cpath id='Vector' d='M7 10.5L12 15.5L17 10.5' stroke='%234A556C' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/g%3E%3C/svg%3E");
36
+ }
37
+
38
+ .vitro-button-expand {
39
+ /* collapse-right.svg URL-encoder for SVG */
40
+ background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 26' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cg id='chevron-right' filter='url(%23filter0_dd_2119_118517)'%3E%3Cpath id='Vector' d='M10.5 17L15.5 12L10.5 7' stroke='%234A556C' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/g%3E%3C/svg%3E");
41
+ }
42
+
43
+ .vitro-button-hide-comment {
44
+ /* comment-hidden.svg URL-encoder for SVG */
45
+ background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M8.5 19H8C3 19 2 19 2 14V9C2 4 3 3 8 3H16C21 3 22 4 22 9V14C22 18 21 19 16 19H15.5C15.19 19 14.89 19.15 14.7 19.4L13.2 21.4C12.54 22.28 11.46 22.28 10.8 21.4L9.3 19.4C9.14 19.18 8.77 19 8.5 19Z' stroke='%234A556C' stroke-miterlimit='10' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M16.9918 11.75H17.0052' stroke='%234A556C' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M11.9918 11.75H12.0052' stroke='%234A556C' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M6.99176 11.75H7.00523' stroke='%234A556C' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M22 2L2 22' stroke='%23222D44' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E%0A");
46
+ }
47
+
48
+ .vitro-button-show-comment {
49
+ /* comment.svg URL-encoder for SVG */
50
+ background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M8.5 19H8C3 19 2 19 2 14V9C2 4 3 3 8 3H16C21 3 22 4 22 9V14C22 18 21 19 16 19H15.5C15.19 19 14.89 19.15 14.7 19.4L13.2 21.4C12.54 22.28 11.46 22.28 10.8 21.4L9.3 19.4C9.14 19.18 8.77 19 8.5 19Z' stroke='%234A556C' stroke-miterlimit='10' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M16.9918 11.75H17.0052' stroke='%234A556C' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M11.9918 11.75H12.0052' stroke='%234A556C' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M6.99176 11.75H7.00523' stroke='%234A556C' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E%0A");
51
+ }
52
+
53
+ .vitro-avatar {
54
+ margin-right: 8px;
55
+ }
56
+
57
+ .vitro-date {
58
+ color: #222D44;
59
+ font-size: 14px;
60
+ font-family: 'InterMedium';
61
+ margin-left: 8px;
62
+ }
63
+
64
+ .vitro-route-item-header {
65
+ width: 100%;
66
+ justify-content: space-between;
67
+ display: flex;
68
+ margin-bottom: 4px;
69
+ }
70
+
71
+ .vitro-route-item-header > div,
72
+ .vitro-route-item-header > div > div {
73
+ display: flex;
74
+ align-items: center;
75
+ }
76
+
77
+ .vitro-route-item-header > div:last-child > div {
78
+ border-radius: 4px;
79
+ background: #F7F9FC;
80
+ padding: 4px 8px;
81
+ margin-left: 12px;
82
+ }
83
+
84
+ .vitro-route-item-header > div:last-child div a,
85
+ .vitro-route-item-header > div:last-child div a:hover,
86
+ .vitro-route-item-header > div:last-child div a:visited {
87
+ text-decoration: none;
88
+ color: #326AD6;
89
+ }
90
+
91
+ .vitro-flex {
92
+ display: flex;
93
+ justify-content: space-between;
94
+ align-items: center;
95
+ }
96
+
97
+ .vitro-comment {
98
+ padding: 4px 8px;
99
+ margin-top: 4px;
100
+ border-radius: 4px;
101
+ background: #F7F9FC;
102
+ color: #222D44;
103
+ font-size: 14px;
104
+ width: 100%;
105
+ }
106
+
107
+ .vitro-status-color {
108
+ width: 8px;
109
+ height: 8px;
110
+ min-width: 8px;
111
+ margin-right: 8px;
112
+ border-radius: 50%;
113
+ }
@@ -0,0 +1,15 @@
1
+ import React from 'react';
2
+ interface RouteItemProps {
3
+ id: string;
4
+ userName: string;
5
+ userImage?: string;
6
+ date: string;
7
+ status: string;
8
+ statusColor?: string;
9
+ name: string;
10
+ comment?: string;
11
+ itemUrl?: string;
12
+ children?: React.ReactNode;
13
+ }
14
+ export declare const RouteItem: (props: RouteItemProps) => JSX.Element;
15
+ export {};
package/dist/index.css CHANGED
@@ -5378,3 +5378,117 @@ ul > li:last-child > ul > li:last-child ._sidebar-item_vitro-active_7p5iOhY {
5378
5378
  ._checkbox-list_vitro-checkbox-list_1iZSkkv span {
5379
5379
  display: block;
5380
5380
  }
5381
+
5382
+ ._route-item_vitro-route-item_bBCgBZG {
5383
+ display: flex;
5384
+ width: 100%;
5385
+ margin-top: 16px;
5386
+ }
5387
+
5388
+ ._route-item_vitro-route-item_bBCgBZG:nth-child(2) {
5389
+ margin-top: 0;
5390
+ }
5391
+
5392
+ ._route-item_vitro-route-item-content_2CcLogk {
5393
+ width: 100%;
5394
+ }
5395
+
5396
+ ._route-item_vitro-button-collapse_1kVB5Vo,
5397
+ ._route-item_vitro-button-expand_3IuABa1,
5398
+ ._route-item_vitro-button-hide-comment_2CiY-Ch,
5399
+ ._route-item_vitro-button-show-comment_DJt2SLC {
5400
+ width: 24px;
5401
+ height: 24px;
5402
+ min-width: 24px;
5403
+ background-position: center;
5404
+ background-size: 100%;
5405
+ border: none;
5406
+ background-color: transparent;
5407
+ }
5408
+
5409
+ ._route-item_vitro-button-collapse_1kVB5Vo,
5410
+ ._route-item_vitro-button-expand_3IuABa1 {
5411
+ margin-right: 12px;
5412
+ }
5413
+
5414
+ ._route-item_vitro-button-collapse_1kVB5Vo {
5415
+ /* collapse-bottom.svg URL-encoder for SVG */
5416
+ background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 25' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cg id='chevron-right' filter='url(%23filter0_dd_2119_119831)'%3E%3Cpath id='Vector' d='M7 10.5L12 15.5L17 10.5' stroke='%234A556C' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/g%3E%3C/svg%3E");
5417
+ }
5418
+
5419
+ ._route-item_vitro-button-expand_3IuABa1 {
5420
+ /* collapse-right.svg URL-encoder for SVG */
5421
+ background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 26' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cg id='chevron-right' filter='url(%23filter0_dd_2119_118517)'%3E%3Cpath id='Vector' d='M10.5 17L15.5 12L10.5 7' stroke='%234A556C' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/g%3E%3C/svg%3E");
5422
+ }
5423
+
5424
+ ._route-item_vitro-button-hide-comment_2CiY-Ch {
5425
+ /* comment-hidden.svg URL-encoder for SVG */
5426
+ background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M8.5 19H8C3 19 2 19 2 14V9C2 4 3 3 8 3H16C21 3 22 4 22 9V14C22 18 21 19 16 19H15.5C15.19 19 14.89 19.15 14.7 19.4L13.2 21.4C12.54 22.28 11.46 22.28 10.8 21.4L9.3 19.4C9.14 19.18 8.77 19 8.5 19Z' stroke='%234A556C' stroke-miterlimit='10' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M16.9918 11.75H17.0052' stroke='%234A556C' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M11.9918 11.75H12.0052' stroke='%234A556C' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M6.99176 11.75H7.00523' stroke='%234A556C' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M22 2L2 22' stroke='%23222D44' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E%0A");
5427
+ }
5428
+
5429
+ ._route-item_vitro-button-show-comment_DJt2SLC {
5430
+ /* comment.svg URL-encoder for SVG */
5431
+ background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M8.5 19H8C3 19 2 19 2 14V9C2 4 3 3 8 3H16C21 3 22 4 22 9V14C22 18 21 19 16 19H15.5C15.19 19 14.89 19.15 14.7 19.4L13.2 21.4C12.54 22.28 11.46 22.28 10.8 21.4L9.3 19.4C9.14 19.18 8.77 19 8.5 19Z' stroke='%234A556C' stroke-miterlimit='10' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M16.9918 11.75H17.0052' stroke='%234A556C' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M11.9918 11.75H12.0052' stroke='%234A556C' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M6.99176 11.75H7.00523' stroke='%234A556C' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E%0A");
5432
+ }
5433
+
5434
+ ._route-item_vitro-avatar_3Dypnmz {
5435
+ margin-right: 8px;
5436
+ }
5437
+
5438
+ ._route-item_vitro-date_3ojnKSb {
5439
+ color: #222D44;
5440
+ font-size: 14px;
5441
+ font-family: 'InterMedium';
5442
+ margin-left: 8px;
5443
+ }
5444
+
5445
+ ._route-item_vitro-route-item-header_y69bLwZ {
5446
+ width: 100%;
5447
+ justify-content: space-between;
5448
+ display: flex;
5449
+ margin-bottom: 4px;
5450
+ }
5451
+
5452
+ ._route-item_vitro-route-item-header_y69bLwZ > div,
5453
+ ._route-item_vitro-route-item-header_y69bLwZ > div > div {
5454
+ display: flex;
5455
+ align-items: center;
5456
+ }
5457
+
5458
+ ._route-item_vitro-route-item-header_y69bLwZ > div:last-child > div {
5459
+ border-radius: 4px;
5460
+ background: #F7F9FC;
5461
+ padding: 4px 8px;
5462
+ margin-left: 12px;
5463
+ }
5464
+
5465
+ ._route-item_vitro-route-item-header_y69bLwZ > div:last-child div a,
5466
+ ._route-item_vitro-route-item-header_y69bLwZ > div:last-child div a:hover,
5467
+ ._route-item_vitro-route-item-header_y69bLwZ > div:last-child div a:visited {
5468
+ text-decoration: none;
5469
+ color: #326AD6;
5470
+ }
5471
+
5472
+ ._route-item_vitro-flex_3ebkqZ9 {
5473
+ display: flex;
5474
+ justify-content: space-between;
5475
+ align-items: center;
5476
+ }
5477
+
5478
+ ._route-item_vitro-comment_2K7RwrZ {
5479
+ padding: 4px 8px;
5480
+ margin-top: 4px;
5481
+ border-radius: 4px;
5482
+ background: #F7F9FC;
5483
+ color: #222D44;
5484
+ font-size: 14px;
5485
+ width: 100%;
5486
+ }
5487
+
5488
+ ._route-item_vitro-status-color_VgXzXKD {
5489
+ width: 8px;
5490
+ height: 8px;
5491
+ min-width: 8px;
5492
+ margin-right: 8px;
5493
+ border-radius: 50%;
5494
+ }
package/dist/index.d.ts CHANGED
@@ -74,6 +74,7 @@ import { Search } from './controls/Search/Search';
74
74
  import { FieldIterator } from './controls/FieldIterator/FieldIterator';
75
75
  import { Tooltip } from './controls/Tooltip/Tooltip';
76
76
  import * as TOOLTIP from './controls/Tooltip/TooltipConstants';
77
+ import { RouteItem } from './controls/RouteItem/RouteItem';
77
78
  export { Breadcrumbs };
78
79
  export { TopLevelMenu };
79
80
  export { TreeView, TreeViewContext, TREE_VIEW, TreeViewProps };
@@ -118,3 +119,4 @@ export { FieldIterator };
118
119
  export { Tooltip, TOOLTIP };
119
120
  export { CONTROL };
120
121
  export { PasswordInput };
122
+ export { RouteItem };
package/dist/index.js CHANGED
@@ -65682,6 +65682,53 @@ var Search = function Search(props) {
65682
65682
  }))));
65683
65683
  };
65684
65684
 
65685
+ var styles$Q = {"vitro-route-item":"_route-item_vitro-route-item_bBCgBZG","vitro-route-item-content":"_route-item_vitro-route-item-content_2CcLogk","vitro-button-collapse":"_route-item_vitro-button-collapse_1kVB5Vo","vitro-button-expand":"_route-item_vitro-button-expand_3IuABa1","vitro-button-hide-comment":"_route-item_vitro-button-hide-comment_2CiY-Ch","vitro-button-show-comment":"_route-item_vitro-button-show-comment_DJt2SLC","vitro-avatar":"_route-item_vitro-avatar_3Dypnmz","vitro-date":"_route-item_vitro-date_3ojnKSb","vitro-route-item-header":"_route-item_vitro-route-item-header_y69bLwZ","vitro-flex":"_route-item_vitro-flex_3ebkqZ9","vitro-comment":"_route-item_vitro-comment_2K7RwrZ","vitro-status-color":"_route-item_vitro-status-color_VgXzXKD"};
65686
+
65687
+ var RouteItem = function RouteItem(props) {
65688
+ var _useState = React.useState(false),
65689
+ isExpanded = _useState[0],
65690
+ setIsExpanded = _useState[1];
65691
+ var _useState2 = React.useState(false),
65692
+ isShowComment = _useState2[0],
65693
+ setIsShowComment = _useState2[1];
65694
+ return React__default.createElement("div", {
65695
+ className: styles$Q['vitro-route-item']
65696
+ }, props.children ? React__default.createElement("button", {
65697
+ className: isExpanded ? styles$Q['vitro-button-collapse'] : styles$Q['vitro-button-expand'],
65698
+ onClick: function onClick() {
65699
+ return setIsExpanded(!isExpanded);
65700
+ }
65701
+ }) : null, React__default.createElement("div", {
65702
+ className: styles$Q['vitro-route-item-content']
65703
+ }, React__default.createElement("div", {
65704
+ className: styles$Q['vitro-route-item-header']
65705
+ }, React__default.createElement("div", null, React__default.createElement("div", null, React__default.createElement(Avatar, {
65706
+ userName: props.userName,
65707
+ image: props.userImage,
65708
+ className: styles$Q['vitro-avatar']
65709
+ }), props.userName), React__default.createElement("div", {
65710
+ className: styles$Q['vitro-date']
65711
+ }, props.date)), React__default.createElement("div", null, React__default.createElement("div", null, props.statusColor && React__default.createElement("div", {
65712
+ className: styles$Q['vitro-status-color'],
65713
+ style: {
65714
+ background: props.statusColor
65715
+ }
65716
+ }), props.status), React__default.createElement("div", null, React__default.createElement("a", {
65717
+ href: props.itemUrl
65718
+ }, CTRL.SHARP + props.id)))), React__default.createElement("div", null, React__default.createElement("div", {
65719
+ className: styles$Q['vitro-flex']
65720
+ }, React__default.createElement("span", null, props.name), props.comment && React__default.createElement("button", {
65721
+ className: isShowComment ? styles$Q['vitro-button-hide-comment'] : styles$Q['vitro-button-show-comment'],
65722
+ onClick: function onClick() {
65723
+ return setIsShowComment(!isShowComment);
65724
+ }
65725
+ })), isShowComment && props.comment && React__default.createElement("div", {
65726
+ className: styles$Q['vitro-comment']
65727
+ }, props.comment)), isExpanded && React__default.createElement("div", {
65728
+ className: styles$Q['vitro-route-item-child']
65729
+ }, props.children)));
65730
+ };
65731
+
65685
65732
  exports.ACTION_HANDLER = ActionHandlerConstants;
65686
65733
  exports.ALERT = AlertConstants;
65687
65734
  exports.ActionHandler = ActionHandler;
@@ -65722,6 +65769,7 @@ exports.NUMBER_INPUT = NumberInputConstants;
65722
65769
  exports.NumberInput = NumberInput;
65723
65770
  exports.PasswordInput = PasswordInput;
65724
65771
  exports.PdfViewer = PdfViewer;
65772
+ exports.RouteItem = RouteItem;
65725
65773
  exports.ScrollBar = ScrollBar;
65726
65774
  exports.Search = Search;
65727
65775
  exports.Sidebar = Sidebar;