@linzjs/windows 9.5.6 → 10.1.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/README.md +1 -1
- package/dist/LuiModalAsync/LuiModalAsync.scss +45 -21
- package/dist/LuiModalAsync/LuiModalAsync.tsx +1 -3
- package/dist/LuiModalAsync/LuiModalAsyncHeader.tsx +2 -1
- package/dist/components/CopyableText.scss +3 -1
- package/dist/components/CopyableText.tsx +1 -1
- package/dist/index.scss +30 -0
- package/dist/panel/Panel.scss +20 -6
- package/dist/panel/Panel.tsx +1 -3
- package/dist/panel/PanelBlue.scss +1 -1
- package/dist/panel/PanelInline.tsx +7 -4
- package/dist/panel/openExternalWindow.ts +1 -1
- package/dist/ribbon/Ribbon.scss +7 -1
- package/dist/ribbon/RibbonButton.tsx +1 -1
- package/dist/ribbon/RibbonButtonLink.tsx +1 -1
- package/dist/ribbon/RibbonButtonOpenPanel.tsx +1 -1
- package/dist/ribbon/RibbonContainer.tsx +1 -1
- package/dist/ribbon/RibbonMenu.scss +1 -1
- package/dist/ribbon/RibbonMenuOption.tsx +1 -1
- package/dist/ribbon/RibbonMenuSeparator.tsx +1 -1
- package/dist/ribbon/RibbonSeparator.tsx +1 -1
- package/dist/ribbon/RibbonSliderButton.tsx +1 -1
- package/dist/ribbon/stories/RibbonDemo.scss +30 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -579,7 +579,7 @@ export const TestShowPanelWithGlobalModal = () => (
|
|
|
579
579
|
|
|
580
580
|
A toolbar ribbon with buttons, sliders, menus, and separators. Supports horizontal and vertical orientations.
|
|
581
581
|
|
|
582
|
-

|
|
582
|
+

|
|
583
583
|

|
|
584
584
|

|
|
585
585
|
**Setup** — requires both `LuiModalAsyncContextProvider` and `PanelsContextProvider`:
|
|
@@ -1,44 +1,68 @@
|
|
|
1
|
-
@use "@linzjs/lui/dist/scss/
|
|
1
|
+
@use "@linzjs/lui/dist/scss/Foundation/Variables/ColorVars" as colors;
|
|
2
|
+
@use "@linzjs/lui/dist/scss/Foundation/Utilities/BoxShadow" as shadow;
|
|
3
|
+
@use "@linzjs/lui/dist/scss/Foundation/Variables/SpacingVars" as spacing;
|
|
4
|
+
@use "@linzjs/lui/dist/scss/Foundation/Variables/FormVars" as form;
|
|
5
|
+
@use "@linzjs/lui/dist/scss/Foundation/Variables/FontVars" as fonts;
|
|
6
|
+
@use "@linzjs/lui/dist/scss/Foundation/Utilities/REM" as rem;
|
|
7
|
+
|
|
8
|
+
dialog.LuiModalAsync, div.LuiModalAsync {
|
|
9
|
+
@include fonts.font-regular();
|
|
10
|
+
font-size: fonts.$base-font-size;
|
|
11
|
+
line-height: fonts.$base-line-height;
|
|
12
|
+
color: colors.$base-type-color;
|
|
13
|
+
|
|
14
|
+
.LuiModalAsync-header {
|
|
15
|
+
h4 {
|
|
16
|
+
@include fonts.font-regular();
|
|
17
|
+
font-size: rem.toRem(22px);
|
|
18
|
+
line-height: 1.5;
|
|
19
|
+
margin-bottom: 0;
|
|
20
|
+
color: colors.$heading-color;
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
}
|
|
2
24
|
|
|
3
25
|
dialog.LuiModalAsync::backdrop {
|
|
4
26
|
background: rgb(0 0 0 / 10%);
|
|
5
27
|
}
|
|
6
28
|
|
|
7
29
|
dialog.LuiModalAsync, div.LuiModalAsync {
|
|
8
|
-
|
|
30
|
+
box-sizing: border-box;
|
|
31
|
+
|
|
32
|
+
@include shadow.drop-shadow(sm);
|
|
9
33
|
border: none;
|
|
10
34
|
display: flex;
|
|
11
35
|
flex-direction: column;
|
|
12
36
|
border-radius: 9px;
|
|
13
|
-
padding:
|
|
37
|
+
padding: spacing.$unit-md;
|
|
14
38
|
min-width: 400px;
|
|
15
39
|
max-width: 80vw;
|
|
16
40
|
max-height: 80vh;
|
|
17
|
-
gap:
|
|
41
|
+
gap: spacing.$unit-md;
|
|
18
42
|
|
|
19
43
|
&:focus-visible {
|
|
20
44
|
outline: none;
|
|
21
45
|
}
|
|
22
46
|
|
|
23
47
|
.LuiModalAsync-header-icon {
|
|
24
|
-
fill:
|
|
48
|
+
fill: colors.$info;
|
|
25
49
|
}
|
|
26
50
|
|
|
27
51
|
.LuiModalAsync-help-icon * {
|
|
28
|
-
fill:
|
|
52
|
+
fill: colors.$gray;
|
|
29
53
|
}
|
|
30
54
|
|
|
31
55
|
&.LuiModalPrefab-success {
|
|
32
56
|
.LuiModalAsync-header .LuiModalAsync-header-icon {
|
|
33
|
-
fill:
|
|
57
|
+
fill: colors.$success;
|
|
34
58
|
}
|
|
35
59
|
|
|
36
|
-
border-left:
|
|
60
|
+
border-left: spacing.$unit-xs solid colors.$success;
|
|
37
61
|
}
|
|
38
62
|
|
|
39
63
|
&.LuiModalPrefab-info {
|
|
40
64
|
.LuiModalAsync-header .LuiModalAsync-header-icon {
|
|
41
|
-
fill:
|
|
65
|
+
fill: colors.$info;
|
|
42
66
|
}
|
|
43
67
|
|
|
44
68
|
border-left: 0;
|
|
@@ -46,23 +70,23 @@ dialog.LuiModalAsync, div.LuiModalAsync {
|
|
|
46
70
|
|
|
47
71
|
&.LuiModalPrefab-warning {
|
|
48
72
|
.LuiModalAsync-header .LuiModalAsync-header-icon {
|
|
49
|
-
fill:
|
|
73
|
+
fill: colors.$warning;
|
|
50
74
|
}
|
|
51
75
|
|
|
52
|
-
border-left:
|
|
76
|
+
border-left: spacing.$unit-xs solid colors.$warning;
|
|
53
77
|
}
|
|
54
78
|
|
|
55
79
|
&.LuiModalPrefab-error {
|
|
56
80
|
.LuiModalAsync-header .LuiModalAsync-header-icon {
|
|
57
|
-
fill:
|
|
81
|
+
fill: colors.$error;
|
|
58
82
|
}
|
|
59
83
|
|
|
60
|
-
border-left:
|
|
84
|
+
border-left: spacing.$unit-sm solid colors.$error;
|
|
61
85
|
}
|
|
62
86
|
|
|
63
87
|
&.LuiModalPrefab-blocked {
|
|
64
88
|
.LuiModalAsync-header .LuiModalAsync-header-icon {
|
|
65
|
-
fill:
|
|
89
|
+
fill: colors.$fuscous;
|
|
66
90
|
}
|
|
67
91
|
|
|
68
92
|
border-left: 0;
|
|
@@ -87,14 +111,14 @@ dialog.LuiModalAsync, div.LuiModalAsync {
|
|
|
87
111
|
|
|
88
112
|
.LuiModalAsync-header {
|
|
89
113
|
display: flex;
|
|
90
|
-
gap:
|
|
114
|
+
gap: spacing.$unit-xs;
|
|
91
115
|
|
|
92
116
|
flex-direction: row;
|
|
93
117
|
align-items: center;
|
|
94
118
|
|
|
95
119
|
h4 {
|
|
96
120
|
flex: 1;
|
|
97
|
-
color:
|
|
121
|
+
color: colors.$charcoal;
|
|
98
122
|
}
|
|
99
123
|
}
|
|
100
124
|
|
|
@@ -102,7 +126,7 @@ dialog.LuiModalAsync, div.LuiModalAsync {
|
|
|
102
126
|
display: flex;
|
|
103
127
|
flex-direction: column;
|
|
104
128
|
flex: 1 1 auto;
|
|
105
|
-
gap:
|
|
129
|
+
gap: spacing.$unit-rg;
|
|
106
130
|
overflow: hidden;
|
|
107
131
|
}
|
|
108
132
|
|
|
@@ -114,15 +138,15 @@ dialog.LuiModalAsync, div.LuiModalAsync {
|
|
|
114
138
|
|
|
115
139
|
.lui-button:focus {
|
|
116
140
|
// Button focus not showing unless window content has focus
|
|
117
|
-
outline:
|
|
141
|
+
outline: form.$input-border-width-thick solid colors.$input-focus;
|
|
118
142
|
}
|
|
119
143
|
}
|
|
120
144
|
|
|
121
145
|
dialog.LuiModalPrefab-file {
|
|
122
|
-
gap:
|
|
123
|
-
padding:
|
|
146
|
+
gap: spacing.$unit-sm;
|
|
147
|
+
padding: spacing.$unit-md;
|
|
124
148
|
|
|
125
149
|
.LuiModalAsync-content {
|
|
126
|
-
padding-bottom:
|
|
150
|
+
padding-bottom: spacing.$unit-xs;
|
|
127
151
|
}
|
|
128
152
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import '
|
|
1
|
+
import '../index.scss';
|
|
2
2
|
|
|
3
3
|
import { LuiButton, LuiIcon } from '@linzjs/lui';
|
|
4
4
|
import { LuiIconName } from '@linzjs/lui/dist/assets/svg-content';
|
|
@@ -13,6 +13,7 @@ export interface LuiModalAsyncHeaderProps {
|
|
|
13
13
|
closeButton?: true;
|
|
14
14
|
helpLink?: string;
|
|
15
15
|
onHelpClick?: () => void;
|
|
16
|
+
// @Deprecated This has no effect. Don't use it
|
|
16
17
|
helpButtonLevel?: 'text' | 'plain-text' | 'primary' | 'secondary' | 'tertiary' | 'success' | 'error';
|
|
17
18
|
}
|
|
18
19
|
|
|
@@ -1,10 +1,12 @@
|
|
|
1
|
-
@use "@linzjs/lui/dist/scss/
|
|
1
|
+
@use "@linzjs/lui/dist/scss/Foundation/Variables/ColorVars" as lui;
|
|
2
2
|
|
|
3
3
|
.CopyToClipboard {
|
|
4
4
|
cursor: pointer;
|
|
5
5
|
}
|
|
6
6
|
|
|
7
7
|
.windows_tooltip {
|
|
8
|
+
box-sizing: border-box;
|
|
9
|
+
|
|
8
10
|
position: relative;
|
|
9
11
|
cursor: pointer;
|
|
10
12
|
|
package/dist/index.scss
ADDED
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
@use './panel/PanelBlue';
|
|
2
|
+
@use './panel/Panel';
|
|
3
|
+
@use './ribbon/RibbonMenu';
|
|
4
|
+
@use './ribbon/stories/RibbonDemo';
|
|
5
|
+
@use './ribbon/Ribbon';
|
|
6
|
+
@use './components/CopyableText';
|
|
7
|
+
@use './LuiModalAsync/LuiModalAsync';
|
|
8
|
+
|
|
9
|
+
@use '@linzjs/lui/dist/scss/Elements/Buttons/buttons-linz';
|
|
10
|
+
@use '@linzjs/lui/dist/scss/Elements/Buttons/buttons';
|
|
11
|
+
@use '@linzjs/lui/dist/scss/Elements/Icons/icons';
|
|
12
|
+
@use '@linzjs/lui/dist/scss/Elements/Tooltips/tippy';
|
|
13
|
+
@use '@linzjs/lui/dist/scss/Components/LuiFormElements/LuiCheckboxInput/LuiCheckboxInput';
|
|
14
|
+
@use '@linzjs/lui/dist/scss/Components/LuiTabs/LuiTabs';
|
|
15
|
+
@use '@linzjs/lui/dist/scss/Components/LuiIcon/LuiIcons';
|
|
16
|
+
@use '@linzjs/lui/dist/scss/Components/Spinner/spinner';
|
|
17
|
+
@use '@linzjs/lui/dist/scss/Components/LuiLoadingSpinner/LuiLoadingSpinner';
|
|
18
|
+
@use '@linzjs/lui/dist/scss/Components/LuiFormElements/LuiFileInputBox';
|
|
19
|
+
@use '@linzjs/lui/dist/scss/Foundation/Utilities/BoxShadow';
|
|
20
|
+
|
|
21
|
+
.LuiCheckboxInput.LuiCheckboxInput--nomargin {
|
|
22
|
+
margin-bottom: 0;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
// set universal box sizing, plus the declaration in the HTML above
|
|
26
|
+
*,
|
|
27
|
+
*:before,
|
|
28
|
+
*:after {
|
|
29
|
+
box-sizing: inherit;
|
|
30
|
+
}
|
package/dist/panel/Panel.scss
CHANGED
|
@@ -1,4 +1,16 @@
|
|
|
1
|
-
@use "@linzjs/lui/dist/scss/
|
|
1
|
+
@use "@linzjs/lui/dist/scss/Foundation/Variables/ColorVars" as colors;
|
|
2
|
+
@use "@linzjs/lui/dist/scss/Foundation/Variables/FontVars" as fonts;
|
|
3
|
+
|
|
4
|
+
.WindowPanel, .PopoutWindowContainer {
|
|
5
|
+
@include fonts.font-regular();
|
|
6
|
+
font-size: fonts.$base-font-size;
|
|
7
|
+
line-height: fonts.$base-line-height;
|
|
8
|
+
color: colors.$base-type-color;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
.LuiCheckboxInput--nomargin {
|
|
12
|
+
margin: 0;
|
|
13
|
+
}
|
|
2
14
|
|
|
3
15
|
.panelDock > .panelDock-content:not(:empty) + .panelDock-empty {
|
|
4
16
|
display: none;
|
|
@@ -15,13 +27,13 @@
|
|
|
15
27
|
height: 48px;
|
|
16
28
|
line-height: 48px;
|
|
17
29
|
user-select: none;
|
|
18
|
-
color:
|
|
30
|
+
color: colors.$charcoal;
|
|
19
31
|
padding: 0 16px;
|
|
20
32
|
display: flex;
|
|
21
33
|
white-space: nowrap;
|
|
22
34
|
overflow: hidden;
|
|
23
35
|
justify-content: space-between;
|
|
24
|
-
border-bottom: 2px
|
|
36
|
+
border-bottom: 2px colors.$lily solid;
|
|
25
37
|
font-size: 1em;
|
|
26
38
|
font-weight: 600;
|
|
27
39
|
flex-direction: row;
|
|
@@ -59,6 +71,8 @@
|
|
|
59
71
|
}
|
|
60
72
|
|
|
61
73
|
.WindowPanel {
|
|
74
|
+
box-sizing: border-box;
|
|
75
|
+
|
|
62
76
|
box-shadow: 0 1px 6px 0 #00000026, 0 6px 10px 0 #00000040;
|
|
63
77
|
background-color: #fff;
|
|
64
78
|
display: flex;
|
|
@@ -71,8 +85,8 @@
|
|
|
71
85
|
}
|
|
72
86
|
|
|
73
87
|
%WindowPanel-divider {
|
|
74
|
-
border-left: 2px solid
|
|
75
|
-
background-color:
|
|
88
|
+
border-left: 2px solid colors.$lily;
|
|
89
|
+
background-color: colors.$lily;
|
|
76
90
|
width: 0;
|
|
77
91
|
height: 19px;
|
|
78
92
|
}
|
|
@@ -113,7 +127,7 @@
|
|
|
113
127
|
}
|
|
114
128
|
|
|
115
129
|
.WindowPanel-header-title-icon {
|
|
116
|
-
fill:
|
|
130
|
+
fill: colors.$fuscous !important;
|
|
117
131
|
margin-right: 8px;
|
|
118
132
|
}
|
|
119
133
|
|
package/dist/panel/Panel.tsx
CHANGED
|
@@ -1,15 +1,18 @@
|
|
|
1
|
-
import { PropsWithChildren } from 'react';
|
|
1
|
+
import { CSSProperties, PropsWithChildren } from 'react';
|
|
2
2
|
|
|
3
3
|
import { PanelContext } from './PanelContext';
|
|
4
4
|
import { PanelInstanceContext } from './PanelInstanceContext';
|
|
5
5
|
import { v4 } from '../common/uuid';
|
|
6
|
+
import clsx from 'clsx';
|
|
6
7
|
|
|
7
8
|
export interface PanelInlineProps {
|
|
8
9
|
title: string;
|
|
9
|
-
|
|
10
|
+
className?: string;
|
|
11
|
+
width?: CSSProperties['width'];
|
|
12
|
+
height?: CSSProperties['height'];
|
|
10
13
|
}
|
|
11
14
|
|
|
12
|
-
export const PanelInline = ({ title, width, children }: PropsWithChildren<PanelInlineProps>) => {
|
|
15
|
+
export const PanelInline = ({ title, className, width, height, children }: PropsWithChildren<PanelInlineProps>) => {
|
|
13
16
|
return (
|
|
14
17
|
<PanelContext.Provider value={{ resizeable: false, resizePanel: () => {}, initialResizePanel: () => {} }}>
|
|
15
18
|
<PanelInstanceContext.Provider
|
|
@@ -31,7 +34,7 @@ export const PanelInline = ({ title, width, children }: PropsWithChildren<PanelI
|
|
|
31
34
|
bounds: undefined,
|
|
32
35
|
}}
|
|
33
36
|
>
|
|
34
|
-
<div className={'WindowPanel'} title={title} style={{ width }}>
|
|
37
|
+
<div className={clsx('WindowPanel', className)} title={title} style={{ width, height }}>
|
|
35
38
|
{children}
|
|
36
39
|
</div>
|
|
37
40
|
</PanelInstanceContext.Provider>
|
|
@@ -58,7 +58,7 @@ export const openExternalWindow = ({
|
|
|
58
58
|
}
|
|
59
59
|
// Create a new HTML element to hang our rendering off
|
|
60
60
|
const newMountElement = externalWindow.document.createElement('div');
|
|
61
|
-
newMountElement.className = `PopoutWindowContainer ${className}`;
|
|
61
|
+
newMountElement.className = `PopoutWindowContainer ${className || ''}`;
|
|
62
62
|
setContainerElement(newMountElement);
|
|
63
63
|
externalWindow.document.body.appendChild(newMountElement);
|
|
64
64
|
|
package/dist/ribbon/Ribbon.scss
CHANGED
|
@@ -1,6 +1,12 @@
|
|
|
1
|
-
@use "@linzjs/lui/dist/scss/
|
|
1
|
+
@use "@linzjs/lui/dist/scss/Foundation/Variables/ColorVars" as lui;
|
|
2
2
|
|
|
3
3
|
.RibbonButton {
|
|
4
|
+
box-sizing: border-box;
|
|
5
|
+
|
|
6
|
+
img {
|
|
7
|
+
max-width: 100%;
|
|
8
|
+
}
|
|
9
|
+
|
|
4
10
|
position: relative;
|
|
5
11
|
background-color: transparent;
|
|
6
12
|
padding: 4px;
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
@use "@linzjs/lui/dist/scss/Foundation/Variables/ColorVars" as lui;
|
|
2
|
+
|
|
3
|
+
.RibbonDemoContent {
|
|
4
|
+
padding: 20px 24px 24px 16px;
|
|
5
|
+
gap: 12px;
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
.RibbonDemoSwitch {
|
|
9
|
+
display: flex;
|
|
10
|
+
flex-direction: row;
|
|
11
|
+
gap: 12px;
|
|
12
|
+
align-items: start;
|
|
13
|
+
padding: 12px 0 0;
|
|
14
|
+
|
|
15
|
+
div:first-child {
|
|
16
|
+
display: flex;
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
.RibbonDemoSwitch-textHeader {
|
|
21
|
+
line-height: 20px;
|
|
22
|
+
font-weight: 600;
|
|
23
|
+
font-size: 16px;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
.RibbonDemoSwitch-textDescription {
|
|
27
|
+
font-weight: 400;
|
|
28
|
+
font-size: 14px;
|
|
29
|
+
color: lui.$fuscous;
|
|
30
|
+
}
|