@phillips/seldon 1.240.1 → 1.241.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 +30 -0
- package/dist/_virtual/index10.js +2 -2
- package/dist/_virtual/index11.js +2 -2
- package/dist/_virtual/index6.js +3 -5
- package/dist/_virtual/index7.js +5 -2
- package/dist/_virtual/index8.js +2 -3
- package/dist/_virtual/index9.js +2 -2
- package/dist/components/AddToCalendar/calendarLinks.js +1 -1
- package/dist/components/Button/types.d.ts +1 -0
- package/dist/components/Button/types.js +1 -1
- package/dist/node_modules/ics/dist/index.js +1 -1
- package/dist/node_modules/ics/dist/pipeline/index.js +1 -1
- package/dist/node_modules/prop-types/index.js +1 -1
- package/dist/node_modules/prop-types/node_modules/react-is/index.js +1 -1
- package/dist/node_modules/react-transition-group/esm/CSSTransition.js +1 -1
- package/dist/node_modules/react-transition-group/esm/Transition.js +1 -1
- package/dist/node_modules/react-transition-group/esm/utils/PropTypes.js +1 -1
- package/dist/scss/components/Button/_button.scss +71 -5
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -44,3 +44,33 @@ import { Button } from '@phillips/seldon';
|
|
|
44
44
|
### Contributing Guidelines
|
|
45
45
|
|
|
46
46
|
Before you start contributing to this project please check out our guidelines found [here](/src/docs/CONTRIBUTING.md)
|
|
47
|
+
|
|
48
|
+
### Git worktrees (`new-worktree.sh`)
|
|
49
|
+
|
|
50
|
+
You can use Git [worktrees](https://git-scm.com/docs/git-worktree) to keep multiple branches checked out at once (for example when reviewing a PR or spiking a change) without re-running all setup steps every time.
|
|
51
|
+
|
|
52
|
+
Use the `scripts/new-worktree.sh` helper to create a new worktree and copy ignored files (like `.env`) into the new directory:
|
|
53
|
+
|
|
54
|
+
```bash
|
|
55
|
+
# New worktree at ../my-feature using the current branch
|
|
56
|
+
./scripts/new-worktree.sh ../my-feature
|
|
57
|
+
|
|
58
|
+
# New worktree on an existing branch
|
|
59
|
+
./scripts/new-worktree.sh ../my-feature feature-branch
|
|
60
|
+
|
|
61
|
+
# New worktree with a new branch (e.g. from main)
|
|
62
|
+
./scripts/new-worktree.sh ../my-feature -b new-branch main
|
|
63
|
+
|
|
64
|
+
# Optionally copy node_modules instead of running npm install in the new worktree
|
|
65
|
+
COPY_NODE_MODULES=1 ./scripts/new-worktree.sh ../my-feature
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
The script runs `git worktree add`, copies ignored config files into the new directory, runs `npm install`, and then opens the new worktree in Cursor or VS Code.
|
|
69
|
+
|
|
70
|
+
To remove a worktree, you can run the following command:
|
|
71
|
+
|
|
72
|
+
```bash
|
|
73
|
+
git worktree remove ../my-feature
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
This will remove the worktree from the git repository.
|
package/dist/_virtual/index10.js
CHANGED
package/dist/_virtual/index11.js
CHANGED
package/dist/_virtual/index6.js
CHANGED
|
@@ -1,7 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
var p = /* @__PURE__ */ o();
|
|
4
|
-
const s = /* @__PURE__ */ r(p);
|
|
1
|
+
import { __require as r } from "../node_modules/ics/dist/index.js";
|
|
2
|
+
var i = r();
|
|
5
3
|
export {
|
|
6
|
-
|
|
4
|
+
i as d
|
|
7
5
|
};
|
package/dist/_virtual/index7.js
CHANGED
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
|
|
1
|
+
import { getDefaultExportFromCjs as r } from "./_commonjsHelpers.js";
|
|
2
|
+
import { __require as o } from "../node_modules/prop-types/index.js";
|
|
3
|
+
var p = /* @__PURE__ */ o();
|
|
4
|
+
const s = /* @__PURE__ */ r(p);
|
|
2
5
|
export {
|
|
3
|
-
|
|
6
|
+
s as default
|
|
4
7
|
};
|
package/dist/_virtual/index8.js
CHANGED
package/dist/_virtual/index9.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { d as u } from "../../_virtual/
|
|
1
|
+
import { d as u } from "../../_virtual/index6.js";
|
|
2
2
|
import { isValid as p } from "../../node_modules/date-fns/isValid.js";
|
|
3
3
|
import { toZonedTime as m } from "../../node_modules/date-fns-tz/dist/esm/toZonedTime/index.js";
|
|
4
4
|
import { addHours as i } from "../../node_modules/date-fns/addHours.js";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
var e = /* @__PURE__ */ ((r) => (r.primary = "primary", r.secondary = "secondary", r.tertiary = "tertiary", r.link = "link", r))(e || {}), l = /* @__PURE__ */ ((r) => (r.default = "default", r.small = "small", r))(l || {});
|
|
1
|
+
var e = /* @__PURE__ */ ((r) => (r.primary = "primary", r.secondary = "secondary", r.tertiary = "tertiary", r.destructive = "destructive", r.link = "link", r))(e || {}), l = /* @__PURE__ */ ((r) => (r.default = "default", r.small = "small", r))(l || {});
|
|
2
2
|
export {
|
|
3
3
|
l as ButtonSizes,
|
|
4
4
|
e as ButtonVariants
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { __exports as u } from "../../../../_virtual/
|
|
1
|
+
import { __exports as u } from "../../../../_virtual/index10.js";
|
|
2
2
|
import { __require as o } from "./build.js";
|
|
3
3
|
import { __require as d } from "./format.js";
|
|
4
4
|
import { __require as f } from "./validate.js";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { __module as r } from "../../_virtual/
|
|
1
|
+
import { __module as r } from "../../_virtual/index9.js";
|
|
2
2
|
import { __require as s } from "./node_modules/react-is/index.js";
|
|
3
3
|
import { __require as t } from "./factoryWithTypeCheckers.js";
|
|
4
4
|
import { __require as p } from "./factoryWithThrowingShims.js";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { __module as e } from "../../../../_virtual/
|
|
1
|
+
import { __module as e } from "../../../../_virtual/index11.js";
|
|
2
2
|
import { __require as o } from "./cjs/react-is.production.min.js";
|
|
3
3
|
import { __require as t } from "./cjs/react-is.development.js";
|
|
4
4
|
var r;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import C from "../../@babel/runtime/helpers/esm/extends.js";
|
|
2
2
|
import x from "../../@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js";
|
|
3
3
|
import N from "../../@babel/runtime/helpers/esm/inheritsLoose.js";
|
|
4
|
-
import v from "../../../_virtual/
|
|
4
|
+
import v from "../../../_virtual/index7.js";
|
|
5
5
|
import A from "../../dom-helpers/esm/addClass.js";
|
|
6
6
|
import _ from "../../dom-helpers/esm/removeClass.js";
|
|
7
7
|
import c from "react";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import C from "../../@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js";
|
|
2
2
|
import D from "../../@babel/runtime/helpers/esm/inheritsLoose.js";
|
|
3
|
-
import o from "../../../_virtual/
|
|
3
|
+
import o from "../../../_virtual/index7.js";
|
|
4
4
|
import v from "react";
|
|
5
5
|
import b from "react-dom";
|
|
6
6
|
import T from "./config.js";
|
|
@@ -1,5 +1,8 @@
|
|
|
1
|
+
@use 'sass:color';
|
|
1
2
|
@use '../../allPartials' as *;
|
|
2
3
|
|
|
4
|
+
$destructive-hover-disabled: color.adjust($warning-default, $alpha: -0.5);
|
|
5
|
+
|
|
3
6
|
.#{$px}-button {
|
|
4
7
|
// we need this because we can't be sure that the Text component is being used as a child of the Button component
|
|
5
8
|
@include text($labelMedium);
|
|
@@ -18,8 +21,10 @@
|
|
|
18
21
|
padding: 0 $padding-sm;
|
|
19
22
|
position: relative;
|
|
20
23
|
transition:
|
|
21
|
-
color 0.25s,
|
|
22
|
-
background-color 0.25s
|
|
24
|
+
color 0.25s ease-out,
|
|
25
|
+
background-color 0.25s ease-out,
|
|
26
|
+
border-color 0.25s ease-out,
|
|
27
|
+
box-shadow 0.25s ease-out;
|
|
23
28
|
|
|
24
29
|
&--small {
|
|
25
30
|
height: 32px; // Explicitly defined by design
|
|
@@ -50,20 +55,22 @@
|
|
|
50
55
|
|
|
51
56
|
path {
|
|
52
57
|
fill: $pure-white;
|
|
53
|
-
transition: 0.25s;
|
|
58
|
+
transition: fill 0.25s ease-out;
|
|
54
59
|
}
|
|
55
60
|
}
|
|
56
61
|
|
|
57
62
|
&--primary,
|
|
58
63
|
&--secondary,
|
|
59
|
-
&--tertiary
|
|
64
|
+
&--tertiary,
|
|
65
|
+
&--destructive {
|
|
60
66
|
&.#{$px}-link {
|
|
61
67
|
text-decoration: none;
|
|
62
68
|
}
|
|
63
69
|
}
|
|
64
70
|
|
|
65
71
|
&--primary.#{$px}-link,
|
|
66
|
-
&--secondary.#{$px}-link
|
|
72
|
+
&--secondary.#{$px}-link,
|
|
73
|
+
&--destructive.#{$px}-link {
|
|
67
74
|
font-variation-settings: 'wght' 600;
|
|
68
75
|
|
|
69
76
|
.#{$px}-text {
|
|
@@ -168,6 +175,51 @@
|
|
|
168
175
|
}
|
|
169
176
|
}
|
|
170
177
|
|
|
178
|
+
&--destructive {
|
|
179
|
+
background-color: $white-100;
|
|
180
|
+
border: 2px solid $warning-default;
|
|
181
|
+
color: $warning-default;
|
|
182
|
+
|
|
183
|
+
&:focus-visible {
|
|
184
|
+
background-color: $white-100;
|
|
185
|
+
border-radius: $radius-3xl;
|
|
186
|
+
outline: 2px solid $warning-default;
|
|
187
|
+
outline-offset: 4px;
|
|
188
|
+
}
|
|
189
|
+
|
|
190
|
+
// Spinner inside destructive button uses the same red
|
|
191
|
+
.#{$px}-loader {
|
|
192
|
+
border-color: $warning-default;
|
|
193
|
+
border-bottom-color: transparent;
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
svg {
|
|
197
|
+
fill: $warning-default;
|
|
198
|
+
|
|
199
|
+
path {
|
|
200
|
+
fill: $warning-default;
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
|
|
204
|
+
@include hoverOrActive {
|
|
205
|
+
background-color: $white-100;
|
|
206
|
+
border-color: $destructive-hover-disabled;
|
|
207
|
+
color: $destructive-hover-disabled;
|
|
208
|
+
|
|
209
|
+
svg {
|
|
210
|
+
fill: $destructive-hover-disabled;
|
|
211
|
+
|
|
212
|
+
path {
|
|
213
|
+
fill: $destructive-hover-disabled;
|
|
214
|
+
}
|
|
215
|
+
}
|
|
216
|
+
|
|
217
|
+
&:disabled {
|
|
218
|
+
box-shadow: none;
|
|
219
|
+
}
|
|
220
|
+
}
|
|
221
|
+
}
|
|
222
|
+
|
|
171
223
|
&--tertiary {
|
|
172
224
|
background-color: transparent;
|
|
173
225
|
color: $pure-black;
|
|
@@ -227,6 +279,20 @@
|
|
|
227
279
|
border-color: transparent;
|
|
228
280
|
}
|
|
229
281
|
|
|
282
|
+
&--destructive:disabled {
|
|
283
|
+
background-color: $white-100;
|
|
284
|
+
border-color: $destructive-hover-disabled;
|
|
285
|
+
color: $destructive-hover-disabled;
|
|
286
|
+
|
|
287
|
+
svg {
|
|
288
|
+
fill: $destructive-hover-disabled;
|
|
289
|
+
|
|
290
|
+
path {
|
|
291
|
+
fill: $destructive-hover-disabled;
|
|
292
|
+
}
|
|
293
|
+
}
|
|
294
|
+
}
|
|
295
|
+
|
|
230
296
|
&--link:disabled {
|
|
231
297
|
border: 0;
|
|
232
298
|
}
|