@linzjs/lui 17.29.1-4 → 17.29.1

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.
@@ -102,6 +102,16 @@ $label-line-height: spacing.$unit-md;
102
102
  }
103
103
  }
104
104
 
105
+ .LuiTextInput-sm {
106
+ height: spacing.$unit-lg; // 32px
107
+ padding: {
108
+ top: spacing.$unit-xs;
109
+ right: spacing.$unit-sm;
110
+ bottom: spacing.$unit-xs;
111
+ left: spacing.$unit-sm;
112
+ }
113
+ }
114
+
105
115
  .LuiTextInput-iconPosition {
106
116
  position: absolute;
107
117
  right: 7px;
@@ -122,7 +132,8 @@ $label-line-height: spacing.$unit-md;
122
132
  background-size: 16px 21px;
123
133
  }
124
134
 
125
- .LuiTextInput-error, .LuiTextInput-warning {
135
+ .LuiTextInput-error,
136
+ .LuiTextInput-warning {
126
137
  @include fonts.font-semibold();
127
138
  display: flex; // make sure we have a hanging indent with the icon
128
139
  position: relative;
@@ -137,7 +148,8 @@ $label-line-height: spacing.$unit-md;
137
148
  color: colors.$error;
138
149
  }
139
150
 
140
- .LuiTextInput-error-icon, .LuiTextInput-warning-icon {
151
+ .LuiTextInput-error-icon,
152
+ .LuiTextInput-warning-icon {
141
153
  position: absolute;
142
154
  left: 0;
143
155
  top: 2px;
@@ -45,10 +45,8 @@
45
45
  @forward './Components/ExpandingSection/expanding-section.scss';
46
46
  @forward './Components/Footer/footer.scss';
47
47
  @forward './Components/Header/header.scss';
48
- @forward './Components/HeaderV2/header-v2.scss';
49
48
  @forward './Components/HelpSection/help-section.scss';
50
49
  @forward './Components/Menu/menu.scss';
51
- @forward './Components/MenuV2/menu-v2.scss';
52
50
  @forward './Components/Messaging/messaging.scss';
53
51
  @forward './Components/Modal/modal.scss';
54
52
  @forward './Components/NavDrawer/nav-drawer.scss';
package/package.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "17.29.1-4",
2
+ "version": "17.29.1",
3
3
  "license": "MIT",
4
4
  "repository": {
5
5
  "type": "git",
@@ -73,8 +73,8 @@
73
73
  ],
74
74
  "devDependencies": {
75
75
  "@geometricpanda/storybook-addon-badges": "^0.2.1",
76
- "@linzjs/floating-windows": "0.4.0",
77
76
  "@linzjs/style": "^3.9.0",
77
+ "@linzjs/floating-windows": "0.4.0",
78
78
  "@react-types/shared": "^3.14.0",
79
79
  "@rollup/plugin-commonjs": "^21.0.2",
80
80
  "@rollup/plugin-json": "^4.1.0",
@@ -94,7 +94,6 @@
94
94
  "@storybook/theming": "^6.5.0",
95
95
  "@testing-library/jest-dom": "^5.8.0",
96
96
  "@testing-library/react": "^10.0.4",
97
- "@testing-library/react-hooks": "^8.0.1",
98
97
  "@testing-library/user-event": "^10.4.0",
99
98
  "@types/camelcase": "^5.2.0",
100
99
  "@types/jest": "^25.2.3",
@@ -151,6 +150,7 @@
151
150
  "@react-aria/utils": "^3.13.2",
152
151
  "@react-stately/list": "^3.5.2",
153
152
  "@szhsin/react-menu": "^2.3.3",
153
+ "react-split-grid": "1.0.4",
154
154
  "camelcase": "^6.0.0",
155
155
  "clsx": "^1.1.0",
156
156
  "container-query-polyfill": "0.1.2",
@@ -161,7 +161,6 @@
161
161
  "react-modal": "^3.11.2",
162
162
  "react-query": "2.26.3",
163
163
  "react-select": "^5.1.0",
164
- "react-split-grid": "1.0.4",
165
164
  "resolve-url-loader": "^5.0.0",
166
165
  "svgstore": "^3.0.0-2",
167
166
  "tippy.js": "^6.3.1",
@@ -1,60 +0,0 @@
1
- import { ReactElement, ReactNode } from 'react';
2
- import { ILuiHeaderMenuItem, ILuiIcon } from '../LuiHeader/LuiHeader';
3
- import { ILuiDrawerMenu, ILuiDrawerMenuSection } from '../LuiHeaderMenu/LuiHeaderMenus';
4
- import { Size } from '../common/ResponsiveUtils';
5
- interface ILuiDrawerMenuOptionV2 {
6
- /**
7
- * The material-ui icon name (see https://material.io/resources/icons/?search=account_c&style=round)
8
- */
9
- icon?: string | ReactElement;
10
- /**
11
- * The label shown beside the icon which is aligned at the left of the drawer
12
- */
13
- label: string | ReactElement;
14
- /**
15
- * The badge which is shown which is aligned at the right of the drawer
16
- */
17
- badge?: ReactElement;
18
- /**
19
- * The function to be bound together with closing the drawer on click
20
- */
21
- onClick?: () => void;
22
- }
23
- declare const LuiDrawerMenuOptionsV2: ({ children, }: ILuiIcon & {
24
- children: ReactNode;
25
- }) => JSX.Element;
26
- declare const LuiDrawerMenuOptionV2: ({ icon, label, badge, onClick, }: ILuiDrawerMenuOptionV2) => JSX.Element;
27
- declare const LuiDrawerMenuV2: ({ children, hasStickyHeader, ...menuPropsCopy }: Omit<ILuiHeaderMenuItem, "onClick"> & {
28
- hasStickyHeader?: boolean | undefined;
29
- } & {
30
- children: ReactNode;
31
- }) => JSX.Element;
32
- declare type ILuiDropdownMenuV2 = Omit<ILuiHeaderMenuItem, 'onClick'> & {
33
- /**
34
- * The anchor origin of dropdown, default to left
35
- */
36
- anchorOrigin?: {
37
- horizontal?: 'left' | 'right';
38
- };
39
- /**
40
- * the width of dropdown, default to 'md'
41
- */
42
- size?: Size | 'xxl';
43
- };
44
- declare const LuiDropdownMenuV2: ({ ...restOfProps }: Omit<ILuiHeaderMenuItem, "onClick"> & {
45
- /**
46
- * The anchor origin of dropdown, default to left
47
- */
48
- anchorOrigin?: {
49
- horizontal?: "left" | "right" | undefined;
50
- } | undefined;
51
- /**
52
- * the width of dropdown, default to 'md'
53
- */
54
- size?: Size | "xxl" | undefined;
55
- } & {
56
- children: ReactNode;
57
- }) => JSX.Element;
58
- declare const LuiDrawerMenuSectionV2: (props: ILuiDrawerMenuSection) => JSX.Element;
59
- declare const LuiDrawerMenuDividerV2: () => JSX.Element;
60
- export { LuiDrawerMenuV2, LuiDrawerMenuOptionsV2, LuiDrawerMenuOptionV2, ILuiDropdownMenuV2, LuiDropdownMenuV2, LuiDrawerMenuSectionV2, LuiDrawerMenuDividerV2, ILuiDrawerMenuOptionV2, };
@@ -1,20 +0,0 @@
1
- import React, { ReactNode } from 'react';
2
- import { HeaderSize, ILuiCloseableHeaderMenuItem, ILuiHeaderMenuItem } from '../LuiHeader/LuiHeader';
3
- interface HeaderPropsV2 {
4
- headingText?: string;
5
- size?: HeaderSize;
6
- homeLink?: string | (() => void);
7
- transparent?: boolean;
8
- sticky?: boolean;
9
- appMenu?: ReactNode;
10
- children: ReactNode;
11
- }
12
- declare const LuiHeaderV2: ({ headingText, size, homeLink, transparent, children, sticky, appMenu, }: HeaderPropsV2) => JSX.Element;
13
- declare const LuiHeaderMenuItemV2: React.ForwardRefExoticComponent<ILuiHeaderMenuItem & {
14
- children?: React.ReactNode;
15
- } & React.RefAttributes<HTMLDivElement>>;
16
- interface ILuiCloseableHeaderMenuItemV2 extends ILuiCloseableHeaderMenuItem {
17
- children: ReactNode;
18
- }
19
- declare const LuiCloseableHeaderMenuItemV2: ({ open, setOpen, children, ...props }: ILuiCloseableHeaderMenuItemV2) => JSX.Element;
20
- export { LuiHeaderV2, LuiHeaderMenuItemV2, LuiCloseableHeaderMenuItemV2, ILuiCloseableHeaderMenuItemV2, };
@@ -1,9 +0,0 @@
1
- import { Size } from './ResponsiveUtils';
2
- export declare type Breakpoint = Exclude<Size | 'xxl', 'xs'>;
3
- export declare const breakpoints: Record<Breakpoint, number>;
4
- export declare const breakpointQuery: {
5
- up: (bp: Breakpoint) => string;
6
- down: (bp: Breakpoint) => string;
7
- between: (bp1: Breakpoint, bp2: Breakpoint) => string;
8
- };
9
- export declare const useMediaQuery: (query: string) => boolean;
@@ -1,204 +0,0 @@
1
- @use "../../Foundation/Variables/MiscVars.scss" as misc;
2
- @use "../../Foundation/Variables/ColorVars.scss" as colors;
3
- @use "../../Foundation/Variables/FontVars.scss" as fonts;
4
- @use "../../Foundation/Variables/SpacingVars.scss" as spacing;
5
- @use "../../Foundation/Utilities" as *;
6
-
7
- $headerRowHeightSmV2: 56px;
8
- $headerRowHeightMdV2: 85px;
9
- $headerRowHeightLgV2: 110px;
10
- $swishHeightSmV2: 3px;
11
- $swishHeightLgV2: 6px;
12
- // header height is row height + swish height
13
- // columns in header row is always 100% so it's row and swish that drives the height of the header
14
- $headerHeightSmV2: $headerRowHeightSmV2 + $swishHeightSmV2;
15
- $headerHeightMdV2: $headerRowHeightMdV2 + $swishHeightLgV2;
16
- $headerHeightLgV2: $headerRowHeightLgV2 + $swishHeightLgV2;
17
-
18
- .lui-header-v2 {
19
- @include lui-standard-header-background($swishHeightLgV2);
20
- }
21
-
22
- .lui-header-row-v2 {
23
- display: flex;
24
- justify-content: space-between;
25
- align-items: center;
26
- height: $headerRowHeightMdV2;
27
- padding: spacing.$unit-xxs;
28
- }
29
-
30
- .lui-header-col-v2 {
31
- display: flex;
32
- align-items: center;
33
- flex-wrap: nowrap;
34
- flex: 0 1 auto;
35
- height: 100%;
36
- }
37
-
38
- .lui-header-title-v2 {
39
- white-space: nowrap;
40
-
41
- h1 {
42
- color: colors.$white;
43
- @media only screen {
44
- //I've wrapped this in a media query so it will still print out on a page
45
- display: none;
46
- }
47
- @include breakpoint(sm) {
48
- display: block;
49
- font-size: 2rem;
50
- line-height: 2rem; //line height same as size so vertical placement is true
51
- @include fonts.font-light;
52
- margin: 0;
53
- }
54
- @include breakpoint(md) {
55
- font-size: 2.25rem;
56
- line-height: 2.25rem; //line height same as size so vertical placement is true
57
- }
58
- }
59
- }
60
-
61
- .lui-header-logo-v2 {
62
- a:before {
63
- display: none;
64
- }
65
-
66
- margin-left: spacing.$unit-xs;
67
- margin-right: spacing.$unit-xs;
68
-
69
- @include breakpoint(sm) {
70
- border-right: 1px solid colors.$persian;
71
- padding-right: spacing.$unit-xs;
72
- }
73
-
74
- & .clickable {
75
- cursor: pointer;
76
- }
77
- }
78
-
79
- .linz-logo-v2 {
80
- width: 170px;
81
- @include breakpoint(sm) {
82
- width: 200px;
83
- }
84
- vertical-align: middle;
85
- }
86
-
87
- .lui-header-small-v2 {
88
- .lui-header-row-v2 {
89
- height: $headerRowHeightSmV2;
90
-
91
- .lui-header-col-v2 {
92
- height: 40px;
93
-
94
- .lui-header-logo-v2 {
95
- border: none;
96
- }
97
-
98
- .linz-motif-v2 {
99
- height: 32px;
100
- width: 32px;
101
- vertical-align: middle;
102
- }
103
-
104
- .lui-header-title-v2 {
105
- white-space: nowrap;
106
-
107
- h1 {
108
- color: colors.$white;
109
- font-size: 20px;
110
- line-height: 24px;
111
- @include fonts.font-regular;
112
- margin: 0;
113
- }
114
- }
115
- }
116
- }
117
-
118
- &:after {
119
- height: $swishHeightSmV2;
120
- }
121
- }
122
-
123
- .lui-header-sticky-v2 {
124
- position: fixed;
125
- z-index: 50;
126
- top: 0;
127
- left: 0;
128
- width: 100%;
129
-
130
- & + div,
131
- & + main {
132
- margin-top: $headerHeightMdV2;
133
-
134
- @include breakpoint(md) {
135
- margin-top: $headerHeightLgV2;
136
- }
137
- }
138
-
139
- &.lui-header-small-v2 {
140
- & + div,
141
- & + main {
142
- margin-top: $headerHeightSmV2;
143
- }
144
- }
145
- }
146
-
147
- .lui-header-menu-item-v2 {
148
- .lui-header-menu-button {
149
- @include fonts.font-semibold;
150
- position: relative;
151
- display: flex;
152
- align-items: center;
153
- justify-content: center;
154
-
155
- // still using original name rather than ui-header-menu-icon-v2
156
- // as to avoid create a new version lui-standard-header-background which is used by modal.scss
157
- .lui-header-menu-icon {
158
- display: flex;
159
- align-items: center;
160
- color: colors.$white;
161
- cursor: default;
162
- user-select: none;
163
-
164
- &.clickable:hover {
165
- cursor: pointer;
166
- }
167
-
168
- width: spacing.$unit-xl;
169
- height: spacing.$unit-xl;
170
- align-items: center;
171
- justify-content: center;
172
- &:hover {
173
- background-color: #8321ff;
174
- }
175
-
176
- i {
177
- font-size: rem(32px);
178
- }
179
- }
180
-
181
- .lui-menu-label-v2 {
182
- text-align: left;
183
- margin-left: spacing.$unit-xxs;
184
- margin-right: spacing.$unit-xxs;
185
- }
186
-
187
- .badge-v2 {
188
- position: absolute;
189
- top: 0.3rem;
190
- left: 1.8rem;
191
- width: 1.3rem;
192
- height: 1.3rem;
193
- font-size: 0.8em;
194
- }
195
- }
196
- }
197
-
198
- .badge-v2 {
199
- display: block;
200
- text-align: center;
201
- border-radius: 50%;
202
- background: #cc0000;
203
- color: white;
204
- }
@@ -1,165 +0,0 @@
1
- @use "../../Foundation/Variables/MiscVars.scss" as misc;
2
- @use "../../Foundation/Variables/ColorVars.scss" as colors;
3
- @use '../../Foundation/Variables/FontVars.scss' as fonts;
4
- @use "../../Foundation/Variables/SpacingVars.scss" as spacing;
5
- @use "../../Foundation/Utilities" as *;
6
- @use "../HeaderV2/header-v2.scss" as header;
7
-
8
- @mixin menu-container-v2 {
9
- text-align: left;
10
- background-color: white;
11
- color: colors.$base-type-color;
12
- }
13
-
14
- body.lui-menu-drawer-v2-open {
15
- overflow-y: hidden;
16
- }
17
-
18
- .lui-menu-drawer-v2 {
19
- @include menu-container-v2;
20
- height: 100%;
21
- width: 300px;
22
- max-width: 100%;
23
- position: fixed;
24
- z-index: 1;
25
- top: 0;
26
- right: 0;
27
- overflow-x: hidden;
28
- border-left: 2px solid colors.$lily;
29
- transition: right 0.5s, visibility 0.6s;
30
-
31
- .lui-header-v2 & {
32
- top: header.$headerHeightMdV2;
33
- height: calc(100% - #{header.$headerHeightMdV2});
34
-
35
- @include breakpoint(md) {
36
- top: header.$headerHeightLgV2;
37
- height: calc(100% - #{header.$headerHeightLgV2});
38
- }
39
- }
40
-
41
- .lui-header-small-v2 & {
42
- top: header.$headerHeightSmV2;
43
- height: calc(100% - #{header.$headerHeightSmV2});
44
- }
45
-
46
- &-closed {
47
- right: -300px;
48
- visibility: hidden;
49
- }
50
-
51
- &-options {
52
- hr {
53
- background-color: colors.$lily;
54
- }
55
- }
56
-
57
- &-option {
58
- display: flex;
59
- justify-content: space-between;
60
- padding: 12px 16px;
61
-
62
- &:hover {
63
- cursor: pointer;
64
- background-color: colors.$polar;
65
- }
66
-
67
- &-label {
68
- display: flex;
69
- align-items: center;
70
-
71
- :first-child {
72
- margin-right: 10px;
73
- }
74
-
75
- i {
76
- color: colors.$brand-secondary;
77
- font-size: rem(24px);
78
- }
79
- }
80
-
81
- .badge {
82
- width: 24px;
83
- height: 24px;
84
- }
85
- }
86
- }
87
-
88
- // drop down
89
-
90
- .lui-menu-dropdown-v2 {
91
- animation: growDown 300ms ease-in-out forwards;
92
- transform-origin: top center;
93
- }
94
-
95
- @keyframes menu-dropdown-animation-go-down {
96
- 0% {
97
- transform: scaleY(0);
98
- }
99
- 100% {
100
- transform: scaleY(1);
101
- }
102
- }
103
-
104
- @keyframes menu-dropdown-animation-go-up {
105
- 0% {
106
- transform: scaleY(1);
107
- }
108
- 100% {
109
- transform: scaleY(0);
110
- }
111
- }
112
-
113
- .lui-menu-dropdown-container {
114
- position: relative;
115
-
116
- .lui-menu-dropdown-v2 {
117
- @include menu-container-v2;
118
- position: absolute;
119
- border-radius: misc.$borderRadius;
120
- top: spacing.$unit-xs;
121
-
122
- // animation
123
- animation: menu-dropdown-animation-go-down 200ms ease-in-out forwards;
124
- transform-origin: top center;
125
-
126
- &-closed {
127
- animation: menu-dropdown-animation-go-up 200ms ease-in-out forwards;
128
- transform-origin: top center;
129
- }
130
-
131
- z-index: 900; // primary menu
132
-
133
- &.dropdown-horizontal-left {
134
- left: spacing.$unit-xs;
135
- }
136
-
137
- &.dropdown-horizontal-right {
138
- right: spacing.$unit-xs;
139
- }
140
-
141
- &.dropdown-xxl {
142
- width: 500px;
143
- }
144
-
145
- &.dropdown-xl {
146
- width: 400px;
147
- }
148
-
149
- &.dropdown-lg {
150
- width: 320px;
151
- }
152
-
153
- &.dropdown-md {
154
- width: 260px;
155
- }
156
-
157
- &.dropdown-sm {
158
- width: 200px;
159
- }
160
-
161
- &.dropdown-xs {
162
- width: 150px;
163
- }
164
- }
165
- }