@rubin-epo/epo-widget-lib 0.9.10 → 0.9.12
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/dist/CameraFilter.cjs +1 -1
- package/dist/CameraFilter.js +14 -15
- package/dist/FilterTool.cjs +1 -1
- package/dist/FilterTool.js +1 -1
- package/dist/atomic/Blinker/Blinker.cjs +1 -1
- package/dist/atomic/Blinker/Blinker.js +43 -41
- package/dist/atomic/Blinker/styles.cjs +19 -4
- package/dist/atomic/Blinker/styles.d.ts +272 -0
- package/dist/atomic/Blinker/styles.js +23 -6
- package/dist/atomic/Loader/index.cjs +1 -0
- package/dist/atomic/Loader/index.d.ts +6 -0
- package/dist/atomic/Loader/index.js +8 -0
- package/dist/atomic/Loader/styles.cjs +10 -0
- package/dist/atomic/Loader/styles.d.ts +272 -0
- package/dist/atomic/Loader/styles.js +15 -0
- package/dist/charts/Base/styles.d.ts +1 -1
- package/dist/charts/styles.d.ts +6 -6
- package/dist/layout/Controls/styles.cjs +14 -19
- package/dist/layout/Controls/styles.js +20 -25
- package/dist/widgets/CameraFilter/styles.cjs +21 -20
- package/dist/widgets/CameraFilter/styles.d.ts +13 -4
- package/dist/widgets/CameraFilter/styles.js +50 -47
- package/dist/widgets/FilterTool/styles.d.ts +6 -6
- package/dist/widgets/SourceSelector/Point/Point.cjs +1 -1
- package/dist/widgets/SourceSelector/Point/Point.d.ts +2 -7
- package/dist/widgets/SourceSelector/Point/Point.js +36 -32
- package/dist/widgets/SourceSelector/Point/styles.cjs +4 -6
- package/dist/widgets/SourceSelector/Point/styles.d.ts +482 -4
- package/dist/widgets/SourceSelector/Point/styles.js +5 -7
- package/dist/widgets/SourceSelector/PointSelector/index.cjs +1 -1
- package/dist/widgets/SourceSelector/PointSelector/index.js +35 -34
- package/dist/widgets/SourceSelector/SourceSelector.cjs +1 -1
- package/dist/widgets/SourceSelector/SourceSelector.d.ts +1 -0
- package/dist/widgets/SourceSelector/SourceSelector.js +78 -56
- package/dist/widgets/SourceSelector/styles.cjs +5 -9
- package/dist/widgets/SourceSelector/styles.js +6 -12
- package/dist/widgets/SupernovaThreeVector/Histogram/styles.d.ts +1 -1
- package/dist/widgets/SupernovaThreeVector/Skymap/styles.d.ts +7 -7
- package/package.json +2 -2
|
@@ -1,73 +1,95 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { jsxs as
|
|
3
|
-
import { useState as
|
|
4
|
-
import { useTranslation as
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
2
|
+
import { jsxs as f, jsx as a, Fragment as R } from "react/jsx-runtime";
|
|
3
|
+
import { useState as u } from "react";
|
|
4
|
+
import { useTranslation as U } from "react-i18next";
|
|
5
|
+
import $ from "@rubin-epo/epo-react-lib/IconComposer";
|
|
6
|
+
import v from "../../layout/AspectRatio/index.js";
|
|
7
|
+
import w from "./PointSelector/index.js";
|
|
8
|
+
import G from "../../atomic/Loader/index.js";
|
|
9
|
+
import { BackgroundBlinker as H } from "./styles.js";
|
|
10
|
+
import J from "./Message/Message.js";
|
|
11
|
+
import K from "../../atomic/ElapsedTime/ElapsedTime.js";
|
|
12
|
+
const Q = (n, c) => {
|
|
13
|
+
var r;
|
|
14
|
+
const s = { day: 0, hour: 0 }, o = n[c];
|
|
15
|
+
if (!o)
|
|
16
|
+
return s;
|
|
17
|
+
const e = (o == null ? void 0 : o.date) - ((r = n[0]) == null ? void 0 : r.date);
|
|
18
|
+
return e ? {
|
|
19
|
+
day: Math.round(e) || 0,
|
|
20
|
+
hour: Math.round(24 / e % 24) || 0
|
|
21
|
+
} : s;
|
|
22
|
+
}, b = ({
|
|
23
|
+
width: n = 600,
|
|
24
|
+
height: c = 600,
|
|
25
|
+
selectedSource: s = [],
|
|
26
|
+
sources: o,
|
|
15
27
|
alerts: e = [],
|
|
16
|
-
activeAlertIndex:
|
|
17
|
-
alertChangeCallback:
|
|
18
|
-
selectionCallback:
|
|
19
|
-
blinkConfig:
|
|
20
|
-
isDisplayOnly:
|
|
21
|
-
|
|
28
|
+
activeAlertIndex: r = 0,
|
|
29
|
+
alertChangeCallback: C,
|
|
30
|
+
selectionCallback: d,
|
|
31
|
+
blinkConfig: k,
|
|
32
|
+
isDisplayOnly: i = !1,
|
|
33
|
+
isLoading: L,
|
|
34
|
+
className: V
|
|
22
35
|
}) => {
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
+
var M;
|
|
37
|
+
const [j, x] = u(!0), [B, l] = u(), [F, m] = u(!1), { t: g } = U(), h = "sourceSelectorWidget", p = !j && !L, S = () => {
|
|
38
|
+
l(g("source_selector.messages.failure")), m(!0);
|
|
39
|
+
}, P = (t) => {
|
|
40
|
+
if (!(!p || i))
|
|
41
|
+
if (t) {
|
|
42
|
+
const z = !!o.find(({ id: N }) => N === t), E = !s.includes(t);
|
|
43
|
+
z && E ? (d && d(s.concat(t)), l(
|
|
44
|
+
/* @__PURE__ */ f(R, { children: [
|
|
45
|
+
/* @__PURE__ */ a($, { icon: "checkmark" }),
|
|
46
|
+
g("source_selector.messages.success")
|
|
47
|
+
] })
|
|
48
|
+
), m(!0)) : S();
|
|
49
|
+
} else
|
|
50
|
+
S();
|
|
51
|
+
}, T = () => {
|
|
52
|
+
m(!1);
|
|
53
|
+
}, { day: W, hour: _ } = Q(e, r), q = i ? [(M = e[r]) == null ? void 0 : M.image] : e.map(({ image: t }) => t);
|
|
54
|
+
return /* @__PURE__ */ f(v, { ratio: "square", className: V, children: [
|
|
55
|
+
!i && /* @__PURE__ */ a(
|
|
56
|
+
J,
|
|
36
57
|
{
|
|
37
|
-
onMessageChangeCallback:
|
|
38
|
-
isVisible:
|
|
39
|
-
forIds: [
|
|
40
|
-
children:
|
|
58
|
+
onMessageChangeCallback: T,
|
|
59
|
+
isVisible: F,
|
|
60
|
+
forIds: [h],
|
|
61
|
+
children: B
|
|
41
62
|
}
|
|
42
63
|
),
|
|
43
|
-
/* @__PURE__ */
|
|
44
|
-
|
|
64
|
+
/* @__PURE__ */ f(
|
|
65
|
+
H,
|
|
45
66
|
{
|
|
46
|
-
images:
|
|
47
|
-
activeIndex:
|
|
48
|
-
blinkCallback:
|
|
49
|
-
loadedCallback: () =>
|
|
50
|
-
...
|
|
67
|
+
images: q,
|
|
68
|
+
activeIndex: r,
|
|
69
|
+
blinkCallback: C,
|
|
70
|
+
loadedCallback: () => x(!1),
|
|
71
|
+
...k,
|
|
51
72
|
children: [
|
|
52
|
-
e.length > 0 && !
|
|
53
|
-
/* @__PURE__ */
|
|
54
|
-
|
|
73
|
+
e.length > 0 && !i && /* @__PURE__ */ a(K, { day: W, hour: _ }),
|
|
74
|
+
/* @__PURE__ */ a(
|
|
75
|
+
w,
|
|
55
76
|
{
|
|
56
|
-
id:
|
|
57
|
-
onSelectCallback:
|
|
58
|
-
width:
|
|
59
|
-
height:
|
|
60
|
-
sources:
|
|
61
|
-
selectedSource:
|
|
77
|
+
id: h,
|
|
78
|
+
onSelectCallback: P,
|
|
79
|
+
width: n,
|
|
80
|
+
height: c,
|
|
81
|
+
sources: o,
|
|
82
|
+
selectedSource: s
|
|
62
83
|
}
|
|
63
84
|
)
|
|
64
85
|
]
|
|
65
86
|
}
|
|
66
|
-
)
|
|
87
|
+
),
|
|
88
|
+
!p && /* @__PURE__ */ a(G, {})
|
|
67
89
|
] });
|
|
68
90
|
};
|
|
69
|
-
|
|
70
|
-
const
|
|
91
|
+
b.displayName = "Widgets.SourceSelector";
|
|
92
|
+
const se = b;
|
|
71
93
|
export {
|
|
72
|
-
|
|
94
|
+
se as default
|
|
73
95
|
};
|
|
@@ -1,14 +1,10 @@
|
|
|
1
|
-
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("styled-components"),l=require("../../atomic/Blinker/Blinker.cjs"),
|
|
1
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("styled-components"),l=require("../../atomic/Blinker/Blinker.cjs"),n=t=>t&&t.__esModule?t:{default:t},e=n(o),s=e.default.svg`
|
|
2
|
+
cursor: pointer;
|
|
2
3
|
position: absolute;
|
|
3
|
-
|
|
4
|
+
bottom: 0;
|
|
4
5
|
left: 0;
|
|
5
|
-
|
|
6
|
-
`,r=e.default(l.default)`
|
|
6
|
+
`,u=e.default(l.default)`
|
|
7
7
|
position: absolute;
|
|
8
8
|
width: 100%;
|
|
9
9
|
height: 100%;
|
|
10
|
-
|
|
11
|
-
position: absolute;
|
|
12
|
-
right: var(--PADDING_SMALL, 20px);
|
|
13
|
-
bottom: var(--PADDING_SMALL, 20px);
|
|
14
|
-
`;exports.BackgroundBlinker=r;exports.ElapsedDisplay=u;exports.SVG=a;
|
|
10
|
+
`;exports.BackgroundBlinker=u;exports.SVG=s;
|
|
@@ -1,23 +1,17 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import o from "styled-components";
|
|
3
3
|
import t from "../../atomic/Blinker/Blinker.js";
|
|
4
|
-
|
|
5
|
-
|
|
4
|
+
const r = o.svg`
|
|
5
|
+
cursor: pointer;
|
|
6
6
|
position: absolute;
|
|
7
|
-
|
|
7
|
+
bottom: 0;
|
|
8
8
|
left: 0;
|
|
9
|
-
|
|
10
|
-
`, l = o(t)`
|
|
9
|
+
`, s = o(t)`
|
|
11
10
|
position: absolute;
|
|
12
11
|
width: 100%;
|
|
13
12
|
height: 100%;
|
|
14
|
-
`, n = o(i)`
|
|
15
|
-
position: absolute;
|
|
16
|
-
right: var(--PADDING_SMALL, 20px);
|
|
17
|
-
bottom: var(--PADDING_SMALL, 20px);
|
|
18
13
|
`;
|
|
19
14
|
export {
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
p as SVG
|
|
15
|
+
s as BackgroundBlinker,
|
|
16
|
+
r as SVG
|
|
23
17
|
};
|
|
@@ -195,7 +195,7 @@ export declare const YLabel: import("styled-components").IStyledComponent<"web",
|
|
|
195
195
|
stroke?: string | undefined;
|
|
196
196
|
strokeDasharray?: string | number | undefined;
|
|
197
197
|
strokeDashoffset?: string | number | undefined;
|
|
198
|
-
strokeLinecap?: "inherit" | "
|
|
198
|
+
strokeLinecap?: "inherit" | "square" | "butt" | "round" | undefined;
|
|
199
199
|
strokeLinejoin?: "inherit" | "round" | "miter" | "bevel" | undefined;
|
|
200
200
|
strokeMiterlimit?: string | number | undefined;
|
|
201
201
|
strokeOpacity?: string | number | undefined;
|
|
@@ -195,7 +195,7 @@ export declare const Background: import("styled-components").IStyledComponent<"w
|
|
|
195
195
|
stroke?: string | undefined;
|
|
196
196
|
strokeDasharray?: string | number | undefined;
|
|
197
197
|
strokeDashoffset?: string | number | undefined;
|
|
198
|
-
strokeLinecap?: "inherit" | "
|
|
198
|
+
strokeLinecap?: "inherit" | "square" | "butt" | "round" | undefined;
|
|
199
199
|
strokeLinejoin?: "inherit" | "round" | "miter" | "bevel" | undefined;
|
|
200
200
|
strokeMiterlimit?: string | number | undefined;
|
|
201
201
|
strokeOpacity?: string | number | undefined;
|
|
@@ -677,7 +677,7 @@ export declare const Graticule: import("styled-components").IStyledComponent<"we
|
|
|
677
677
|
stroke?: string | undefined;
|
|
678
678
|
strokeDasharray?: string | number | undefined;
|
|
679
679
|
strokeDashoffset?: string | number | undefined;
|
|
680
|
-
strokeLinecap?: "inherit" | "
|
|
680
|
+
strokeLinecap?: "inherit" | "square" | "butt" | "round" | undefined;
|
|
681
681
|
strokeLinejoin?: "inherit" | "round" | "miter" | "bevel" | undefined;
|
|
682
682
|
strokeMiterlimit?: string | number | undefined;
|
|
683
683
|
strokeOpacity?: string | number | undefined;
|
|
@@ -1159,7 +1159,7 @@ export declare const Outline: import("styled-components").IStyledComponent<"web"
|
|
|
1159
1159
|
stroke?: string | undefined;
|
|
1160
1160
|
strokeDasharray?: string | number | undefined;
|
|
1161
1161
|
strokeDashoffset?: string | number | undefined;
|
|
1162
|
-
strokeLinecap?: "inherit" | "
|
|
1162
|
+
strokeLinecap?: "inherit" | "square" | "butt" | "round" | undefined;
|
|
1163
1163
|
strokeLinejoin?: "inherit" | "round" | "miter" | "bevel" | undefined;
|
|
1164
1164
|
strokeMiterlimit?: string | number | undefined;
|
|
1165
1165
|
strokeOpacity?: string | number | undefined;
|
|
@@ -1641,7 +1641,7 @@ export declare const LatLabel: import("styled-components").IStyledComponent<"web
|
|
|
1641
1641
|
stroke?: string | undefined;
|
|
1642
1642
|
strokeDasharray?: string | number | undefined;
|
|
1643
1643
|
strokeDashoffset?: string | number | undefined;
|
|
1644
|
-
strokeLinecap?: "inherit" | "
|
|
1644
|
+
strokeLinecap?: "inherit" | "square" | "butt" | "round" | undefined;
|
|
1645
1645
|
strokeLinejoin?: "inherit" | "round" | "miter" | "bevel" | undefined;
|
|
1646
1646
|
strokeMiterlimit?: string | number | undefined;
|
|
1647
1647
|
strokeOpacity?: string | number | undefined;
|
|
@@ -2123,7 +2123,7 @@ export declare const LongLabel: import("styled-components").IStyledComponent<"we
|
|
|
2123
2123
|
stroke?: string | undefined;
|
|
2124
2124
|
strokeDasharray?: string | number | undefined;
|
|
2125
2125
|
strokeDashoffset?: string | number | undefined;
|
|
2126
|
-
strokeLinecap?: "inherit" | "
|
|
2126
|
+
strokeLinecap?: "inherit" | "square" | "butt" | "round" | undefined;
|
|
2127
2127
|
strokeLinejoin?: "inherit" | "round" | "miter" | "bevel" | undefined;
|
|
2128
2128
|
strokeMiterlimit?: string | number | undefined;
|
|
2129
2129
|
strokeOpacity?: string | number | undefined;
|
|
@@ -2605,7 +2605,7 @@ export declare const ImageStackerWrapper: import("styled-components").IStyledCom
|
|
|
2605
2605
|
stroke?: string | undefined;
|
|
2606
2606
|
strokeDasharray?: string | number | undefined;
|
|
2607
2607
|
strokeDashoffset?: string | number | undefined;
|
|
2608
|
-
strokeLinecap?: "inherit" | "
|
|
2608
|
+
strokeLinecap?: "inherit" | "square" | "butt" | "round" | undefined;
|
|
2609
2609
|
strokeLinejoin?: "inherit" | "round" | "miter" | "bevel" | undefined;
|
|
2610
2610
|
strokeMiterlimit?: string | number | undefined;
|
|
2611
2611
|
strokeOpacity?: string | number | undefined;
|
|
@@ -3087,7 +3087,7 @@ export declare const UserObject: import("styled-components").IStyledComponent<"w
|
|
|
3087
3087
|
stroke?: string | undefined;
|
|
3088
3088
|
strokeDasharray?: string | number | undefined;
|
|
3089
3089
|
strokeDashoffset?: string | number | undefined;
|
|
3090
|
-
strokeLinecap?: "inherit" | "
|
|
3090
|
+
strokeLinecap?: "inherit" | "square" | "butt" | "round" | undefined;
|
|
3091
3091
|
strokeLinejoin?: "inherit" | "round" | "miter" | "bevel" | undefined;
|
|
3092
3092
|
strokeMiterlimit?: string | number | undefined;
|
|
3093
3093
|
strokeOpacity?: string | number | undefined;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rubin-epo/epo-widget-lib",
|
|
3
|
-
"version": "0.9.
|
|
3
|
+
"version": "0.9.12",
|
|
4
4
|
"description": "Rubin Observatory Education & Public Outreach team React scientific and educational widgets.",
|
|
5
5
|
"author": "Rubin EPO",
|
|
6
6
|
"license": "MIT",
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
"react-i18next": "^12.2.0"
|
|
39
39
|
},
|
|
40
40
|
"dependencies": {
|
|
41
|
-
"@rubin-epo/epo-react-lib": "
|
|
41
|
+
"@rubin-epo/epo-react-lib": "2.0.24",
|
|
42
42
|
"context-filter-polyfill": "^0.3.6",
|
|
43
43
|
"d3-array": "^3.2.4",
|
|
44
44
|
"d3-geo": "^3.1.0",
|