@sentinel-nvr/web 0.21.0 → 0.22.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 +4 -2
- package/dist/chunk-Z5USWUIE.js +1102 -0
- package/dist/chunk-Z5USWUIE.js.map +1 -0
- package/dist/glas/index.js +27 -755
- package/dist/glas/index.js.map +1 -1
- package/dist/ui/glas.css +379 -0
- package/dist/ui/index.js +200 -59
- package/dist/ui/index.js.map +1 -1
- package/dist/ui/locales/de.json +1 -1
- package/dist/ui/locales/es.json +1 -1
- package/dist/ui/locales/fr.json +1 -1
- package/dist/ui/locales/it.json +1 -1
- package/dist/ui/locales/pt.json +1 -1
- package/dist/ui/locales/sv.json +1 -1
- package/package.json +1 -1
- package/dist/chunk-KUDATN2V.js +0 -324
- package/dist/chunk-KUDATN2V.js.map +0 -1
package/dist/ui/glas.css
CHANGED
|
@@ -1248,3 +1248,382 @@
|
|
|
1248
1248
|
border: 1px solid CanvasText;
|
|
1249
1249
|
}
|
|
1250
1250
|
}
|
|
1251
|
+
/* ---- from HAPulse styles/glas/settings.css, pages.css and controls.css (0.22.0): the settings ("Darstellung") ----
|
|
1252
|
+
One iOS settings list, as HAPulse's settings page: the group title 15/20 600 in `label2` above its list, rows 52
|
|
1253
|
+
(inline: 44 inside 4 above and below), the symbol monochrome `label2` in a column of 28 (its colours come inline;
|
|
1254
|
+
the tokens are set on the chip itself), the label 17/22, separators 0.5 px from the text start (56), none above the
|
|
1255
|
+
first row. Explanations start under the label text (desktop) or at the row's inset (phones). The choices are the Glas
|
|
1256
|
+
segment (GlassSegment, `nvr-gl-seg--settings`), the switch, the language as an iOS pop-up row and the accent slider
|
|
1257
|
+
look like HAPulse's controls. Selectors map HAPulse's classes: .settings-card__row → .nvr-set__row,
|
|
1258
|
+
.settings-card__row-label → .nvr-set__label, .settings-card__icon-chip → .nvr-set__chip, .managed-row-hint →
|
|
1259
|
+
.nvr-set__hint, .admin-toggle → .nvr-switch, .settings-select → .nvr-select, .accent-row → .nvr-accent,
|
|
1260
|
+
.accent-slider → .nvr-accent__slider, .g-seg → .nvr-gl-seg. */
|
|
1261
|
+
:root[data-style='glas'] .nvr-set__section {
|
|
1262
|
+
--g-row-indent: 40px;
|
|
1263
|
+
gap: 8px;
|
|
1264
|
+
}
|
|
1265
|
+
@media (max-width: 480px) {
|
|
1266
|
+
:root[data-style='glas'] .nvr-set__section {
|
|
1267
|
+
--g-row-indent: 0px;
|
|
1268
|
+
}
|
|
1269
|
+
}
|
|
1270
|
+
:root[data-style='glas'] .nvr-set__section > .nvr-section__label {
|
|
1271
|
+
padding: 0 16px;
|
|
1272
|
+
color: var(--g-label-2);
|
|
1273
|
+
font: 600 15px / 20px var(--g-font);
|
|
1274
|
+
letter-spacing: normal;
|
|
1275
|
+
text-transform: none;
|
|
1276
|
+
}
|
|
1277
|
+
:root[data-style='glas'] .nvr-set-card {
|
|
1278
|
+
gap: 0;
|
|
1279
|
+
padding: 0;
|
|
1280
|
+
overflow: hidden;
|
|
1281
|
+
}
|
|
1282
|
+
/* rows */
|
|
1283
|
+
:root[data-style='glas'] .nvr-set-card .nvr-set__row {
|
|
1284
|
+
position: relative;
|
|
1285
|
+
gap: 8px;
|
|
1286
|
+
min-height: 52px;
|
|
1287
|
+
padding: 12px 16px;
|
|
1288
|
+
border: 0;
|
|
1289
|
+
}
|
|
1290
|
+
:root[data-style='glas'] .nvr-set-card .nvr-set__row--inline {
|
|
1291
|
+
gap: 0 12px;
|
|
1292
|
+
padding: 4px 16px;
|
|
1293
|
+
}
|
|
1294
|
+
:root[data-style='glas'] .nvr-set-card .nvr-set__row::before {
|
|
1295
|
+
content: '';
|
|
1296
|
+
position: absolute;
|
|
1297
|
+
top: 0;
|
|
1298
|
+
right: 0;
|
|
1299
|
+
left: 56px;
|
|
1300
|
+
height: 0.5px;
|
|
1301
|
+
background: var(--g-sep);
|
|
1302
|
+
pointer-events: none;
|
|
1303
|
+
}
|
|
1304
|
+
:root[data-style='glas'] .nvr-set-card > .nvr-set__row:first-child::before {
|
|
1305
|
+
content: none;
|
|
1306
|
+
}
|
|
1307
|
+
/* label and symbol */
|
|
1308
|
+
:root[data-style='glas'] .nvr-set-card .nvr-set__label {
|
|
1309
|
+
gap: 12px;
|
|
1310
|
+
color: var(--g-label);
|
|
1311
|
+
font: 400 17px / 22px var(--g-font);
|
|
1312
|
+
}
|
|
1313
|
+
:root[data-style='glas'] .nvr-set-card .nvr-set__row--inline > .nvr-set__label {
|
|
1314
|
+
flex: 0 1 auto;
|
|
1315
|
+
min-height: 44px;
|
|
1316
|
+
}
|
|
1317
|
+
/* beside a switch the label wraps, the switch stays at the row's end */
|
|
1318
|
+
:root[data-style='glas'] .nvr-set-card .nvr-set__row--inline:has(> .nvr-switch) > .nvr-set__label {
|
|
1319
|
+
flex: 1 1 0%;
|
|
1320
|
+
min-width: 0;
|
|
1321
|
+
}
|
|
1322
|
+
:root[data-style='glas'] .nvr-set-card .nvr-set__chip {
|
|
1323
|
+
--accent-soft: transparent;
|
|
1324
|
+
--accent: var(--g-label-2);
|
|
1325
|
+
--info-soft: transparent;
|
|
1326
|
+
--info: var(--g-label-2);
|
|
1327
|
+
--warning-soft: transparent;
|
|
1328
|
+
--warning: var(--g-label-2);
|
|
1329
|
+
--bg-subtle: transparent;
|
|
1330
|
+
--text-dim: var(--g-label-2);
|
|
1331
|
+
width: 28px;
|
|
1332
|
+
height: 28px;
|
|
1333
|
+
border-radius: 0;
|
|
1334
|
+
}
|
|
1335
|
+
:root[data-style='glas'] .nvr-set-card .nvr-set__chip > svg {
|
|
1336
|
+
width: 22px;
|
|
1337
|
+
height: 22px;
|
|
1338
|
+
}
|
|
1339
|
+
/* explanations */
|
|
1340
|
+
:root[data-style='glas'] .nvr-set-card .nvr-set__hint {
|
|
1341
|
+
margin: -6px 0 8px;
|
|
1342
|
+
padding-left: var(--g-row-indent);
|
|
1343
|
+
color: var(--g-label-2);
|
|
1344
|
+
font: 400 13px / 18px var(--g-font);
|
|
1345
|
+
}
|
|
1346
|
+
@media (max-width: 480px) {
|
|
1347
|
+
:root[data-style='glas'] .nvr-set-card .nvr-set__hint {
|
|
1348
|
+
margin-top: 0;
|
|
1349
|
+
}
|
|
1350
|
+
}
|
|
1351
|
+
/* language: the value with its chevron at the row's end, like an iOS pop-up row */
|
|
1352
|
+
:root[data-style='glas'] .nvr-set-card .nvr-select {
|
|
1353
|
+
margin-left: auto;
|
|
1354
|
+
}
|
|
1355
|
+
:root[data-style='glas'] .nvr-set-card .nvr-select__native {
|
|
1356
|
+
min-height: 44px;
|
|
1357
|
+
margin-block: 0;
|
|
1358
|
+
padding: 0 24px 0 8px;
|
|
1359
|
+
border: 0;
|
|
1360
|
+
border-radius: 10px;
|
|
1361
|
+
background: transparent;
|
|
1362
|
+
color: var(--g-label-2);
|
|
1363
|
+
font: 400 17px / 22px var(--g-font);
|
|
1364
|
+
text-align: right;
|
|
1365
|
+
text-align-last: right;
|
|
1366
|
+
}
|
|
1367
|
+
@media (hover: hover) {
|
|
1368
|
+
:root[data-style='glas'] .nvr-set-card .nvr-select__native:hover {
|
|
1369
|
+
background-image: none;
|
|
1370
|
+
}
|
|
1371
|
+
}
|
|
1372
|
+
:root[data-style='glas'] .nvr-set-card .nvr-select__native:focus-visible {
|
|
1373
|
+
outline: 2px solid var(--g-focus);
|
|
1374
|
+
outline-offset: 0;
|
|
1375
|
+
box-shadow: none;
|
|
1376
|
+
}
|
|
1377
|
+
:root[data-style='glas'] .nvr-set-card .nvr-select__chevron {
|
|
1378
|
+
right: 2px;
|
|
1379
|
+
color: var(--g-label-3);
|
|
1380
|
+
}
|
|
1381
|
+
/* accent: the label line is always 44 high (inside the row's inset), so "Zurücksetzen" appearing on the first drag
|
|
1382
|
+
does not move the slider under the finger; the slider under the label text */
|
|
1383
|
+
:root[data-style='glas'] .nvr-set-card .nvr-accent {
|
|
1384
|
+
gap: 8px;
|
|
1385
|
+
}
|
|
1386
|
+
:root[data-style='glas'] .nvr-set-card .nvr-accent__label {
|
|
1387
|
+
min-height: 44px;
|
|
1388
|
+
margin: -8px 0;
|
|
1389
|
+
}
|
|
1390
|
+
:root[data-style='glas'] .nvr-set-card .nvr-accent__label > .nvr-set__label {
|
|
1391
|
+
gap: 8px;
|
|
1392
|
+
}
|
|
1393
|
+
:root[data-style='glas'] .nvr-set-card .nvr-accent__label .nvr-set__chip {
|
|
1394
|
+
margin-right: 4px;
|
|
1395
|
+
}
|
|
1396
|
+
:root[data-style='glas'] .nvr-set-card .nvr-accent__dot {
|
|
1397
|
+
width: 16px;
|
|
1398
|
+
height: 16px;
|
|
1399
|
+
margin-left: 8px;
|
|
1400
|
+
border: 0;
|
|
1401
|
+
}
|
|
1402
|
+
:root[data-style='glas'] .nvr-set-card .nvr-accent__reset {
|
|
1403
|
+
display: inline-block;
|
|
1404
|
+
min-height: 44px;
|
|
1405
|
+
padding: 12px 4px;
|
|
1406
|
+
border: 0;
|
|
1407
|
+
background: transparent;
|
|
1408
|
+
color: var(--g-accent-ink);
|
|
1409
|
+
font: 400 17px / 20px var(--g-font);
|
|
1410
|
+
}
|
|
1411
|
+
:root[data-style='glas'] .nvr-set-card .nvr-accent__reset:hover {
|
|
1412
|
+
background: transparent;
|
|
1413
|
+
color: var(--g-accent-ink);
|
|
1414
|
+
}
|
|
1415
|
+
@media (hover: hover) {
|
|
1416
|
+
:root[data-style='glas'] .nvr-set-card .nvr-accent__reset:hover {
|
|
1417
|
+
opacity: 0.7;
|
|
1418
|
+
}
|
|
1419
|
+
}
|
|
1420
|
+
:root[data-style='glas'] .nvr-set-card .nvr-accent__reset:focus-visible {
|
|
1421
|
+
outline: 2px solid var(--g-focus);
|
|
1422
|
+
outline-offset: -2px;
|
|
1423
|
+
border-radius: 10px;
|
|
1424
|
+
}
|
|
1425
|
+
:root[data-style='glas'] .nvr-set-card .nvr-accent__slider {
|
|
1426
|
+
align-self: stretch;
|
|
1427
|
+
width: auto;
|
|
1428
|
+
height: 28px;
|
|
1429
|
+
margin-left: var(--g-row-indent);
|
|
1430
|
+
border: 0;
|
|
1431
|
+
border-radius: 14px;
|
|
1432
|
+
transition: transform 200ms var(--g-spring-snappy);
|
|
1433
|
+
}
|
|
1434
|
+
:root[data-style='glas'] .nvr-set-card .nvr-accent__slider::-webkit-slider-thumb {
|
|
1435
|
+
width: 24px;
|
|
1436
|
+
height: 24px;
|
|
1437
|
+
border: 0;
|
|
1438
|
+
background: var(--g-knob);
|
|
1439
|
+
box-shadow: var(--g-shadow-knob);
|
|
1440
|
+
}
|
|
1441
|
+
:root[data-style='glas'] .nvr-set-card .nvr-accent__slider::-moz-range-thumb {
|
|
1442
|
+
width: 24px;
|
|
1443
|
+
height: 24px;
|
|
1444
|
+
border: 0;
|
|
1445
|
+
background: var(--g-knob);
|
|
1446
|
+
box-shadow: var(--g-shadow-knob);
|
|
1447
|
+
}
|
|
1448
|
+
:root[data-style='glas'] .nvr-set-card .nvr-accent__slider:active {
|
|
1449
|
+
transform: scale(1.04);
|
|
1450
|
+
}
|
|
1451
|
+
:root[data-style='glas'] .nvr-set-card .nvr-accent__slider:focus-visible {
|
|
1452
|
+
outline: 2px solid var(--g-focus);
|
|
1453
|
+
outline-offset: 2px;
|
|
1454
|
+
}
|
|
1455
|
+
/* switch (GLAS-DESIGN §7.28): 51 × 31 capsule, knob 27 white with its shadow, on = iOS green and the knob 20 to the
|
|
1456
|
+
right; hit area 64 × 44 around the capsule without moving anything */
|
|
1457
|
+
:root[data-style='glas'] .nvr-switch {
|
|
1458
|
+
width: 51px;
|
|
1459
|
+
height: 31px;
|
|
1460
|
+
border: 0;
|
|
1461
|
+
border-radius: 16px;
|
|
1462
|
+
background: var(--g-switch-off);
|
|
1463
|
+
box-shadow: none;
|
|
1464
|
+
transition: background-color 250ms ease;
|
|
1465
|
+
}
|
|
1466
|
+
:root[data-style='glas'] .nvr-switch--on {
|
|
1467
|
+
background: var(--g-switch-on);
|
|
1468
|
+
}
|
|
1469
|
+
:root[data-style='glas'] .nvr-switch__thumb {
|
|
1470
|
+
top: 2px;
|
|
1471
|
+
left: 2px;
|
|
1472
|
+
width: 27px;
|
|
1473
|
+
height: 27px;
|
|
1474
|
+
border-radius: 50%;
|
|
1475
|
+
background: var(--g-knob);
|
|
1476
|
+
box-shadow: var(--g-shadow-knob);
|
|
1477
|
+
transition: transform var(--g-d-snappy) var(--g-spring-snappy);
|
|
1478
|
+
}
|
|
1479
|
+
:root[data-style='glas'] .nvr-switch--on .nvr-switch__thumb {
|
|
1480
|
+
background: var(--g-knob);
|
|
1481
|
+
transform: translateX(20px);
|
|
1482
|
+
}
|
|
1483
|
+
:root[data-style='glas'] .nvr-switch::before {
|
|
1484
|
+
content: '';
|
|
1485
|
+
position: absolute;
|
|
1486
|
+
inset: -6.5px;
|
|
1487
|
+
}
|
|
1488
|
+
:root[data-style='glas'] .nvr-switch:focus-visible {
|
|
1489
|
+
outline: 2px solid var(--g-focus);
|
|
1490
|
+
outline-offset: 2px;
|
|
1491
|
+
}
|
|
1492
|
+
/* segmented control (GLAS-DESIGN §7.27, GlassSegment): track `fill`, lens `seg` + `segShadow` that slides with the
|
|
1493
|
+
snappy spring, equally wide options with text only. The size per use comes from a modifier class that sets the
|
|
1494
|
+
variables: --nvr-gl-seg-h (hit area), --nvr-gl-seg-inset (space above and below the visible track),
|
|
1495
|
+
--nvr-gl-seg-pad (space between track and lens). The component sets --nvr-gl-seg-n (options) and --nvr-gl-seg-i
|
|
1496
|
+
(chosen one). */
|
|
1497
|
+
:root[data-style='glas'] .nvr-gl-seg {
|
|
1498
|
+
--nvr-gl-seg-h: 36px;
|
|
1499
|
+
--nvr-gl-seg-inset: 0px;
|
|
1500
|
+
--nvr-gl-seg-pad: 2px;
|
|
1501
|
+
position: relative;
|
|
1502
|
+
display: flex;
|
|
1503
|
+
height: var(--nvr-gl-seg-h);
|
|
1504
|
+
}
|
|
1505
|
+
:root[data-style='glas'] .nvr-gl-seg__track {
|
|
1506
|
+
position: absolute;
|
|
1507
|
+
inset: var(--nvr-gl-seg-inset) 0;
|
|
1508
|
+
border-radius: 999px;
|
|
1509
|
+
background: var(--g-fill);
|
|
1510
|
+
}
|
|
1511
|
+
:root[data-style='glas'] .nvr-gl-seg__lens {
|
|
1512
|
+
position: absolute;
|
|
1513
|
+
top: calc(var(--nvr-gl-seg-inset) + var(--nvr-gl-seg-pad));
|
|
1514
|
+
left: var(--nvr-gl-seg-pad);
|
|
1515
|
+
width: calc((100% - 2 * var(--nvr-gl-seg-pad)) / var(--nvr-gl-seg-n));
|
|
1516
|
+
height: calc(var(--nvr-gl-seg-h) - 2 * (var(--nvr-gl-seg-inset) + var(--nvr-gl-seg-pad)));
|
|
1517
|
+
border-radius: 999px;
|
|
1518
|
+
background: var(--g-seg);
|
|
1519
|
+
box-shadow: var(--g-seg-shadow);
|
|
1520
|
+
transform: translateX(calc(var(--nvr-gl-seg-i) * 100%));
|
|
1521
|
+
transition: transform var(--g-d-snappy) var(--g-spring-snappy);
|
|
1522
|
+
pointer-events: none;
|
|
1523
|
+
}
|
|
1524
|
+
:root[data-style='glas'] .nvr-gl-seg[data-none] .nvr-gl-seg__lens {
|
|
1525
|
+
display: none;
|
|
1526
|
+
}
|
|
1527
|
+
:root[data-style='glas'] .nvr-gl-seg__opt {
|
|
1528
|
+
position: relative;
|
|
1529
|
+
flex: 1 1 0;
|
|
1530
|
+
min-width: 0;
|
|
1531
|
+
height: var(--nvr-gl-seg-h);
|
|
1532
|
+
padding: 0 4px;
|
|
1533
|
+
border: 0;
|
|
1534
|
+
border-radius: 999px;
|
|
1535
|
+
background: transparent;
|
|
1536
|
+
color: var(--g-label);
|
|
1537
|
+
font: 600 13px / 18px var(--g-font);
|
|
1538
|
+
text-align: center;
|
|
1539
|
+
white-space: nowrap;
|
|
1540
|
+
overflow: hidden;
|
|
1541
|
+
text-overflow: ellipsis;
|
|
1542
|
+
cursor: pointer;
|
|
1543
|
+
-webkit-tap-highlight-color: transparent;
|
|
1544
|
+
}
|
|
1545
|
+
:root[data-style='glas'] .nvr-gl-seg__opt:focus-visible {
|
|
1546
|
+
outline: 2px solid var(--accent);
|
|
1547
|
+
outline-offset: 2px;
|
|
1548
|
+
}
|
|
1549
|
+
/* a label that does not fit (GlassSegment measures it): the whole segment 13/18 with 2 px padding; what still does not
|
|
1550
|
+
fit ends in "…" */
|
|
1551
|
+
:root[data-style='glas'] .nvr-gl-seg[data-tight] .nvr-gl-seg__opt {
|
|
1552
|
+
padding: 0 2px;
|
|
1553
|
+
font-size: 13px;
|
|
1554
|
+
line-height: 18px;
|
|
1555
|
+
}
|
|
1556
|
+
/* the settings' choices (style, strength, light/dark): hit area 44, visible track 32, lens 28, at the row's end; the
|
|
1557
|
+
options equally wide as the longest label (at least 72). A transparent border of 2 on each side gives the measuring
|
|
1558
|
+
its slack. Phones: the segment takes its own line in the row's whole width. */
|
|
1559
|
+
:root[data-style='glas'] .nvr-gl-seg--settings {
|
|
1560
|
+
--nvr-gl-seg-h: 44px;
|
|
1561
|
+
--nvr-gl-seg-inset: 6px;
|
|
1562
|
+
--nvr-gl-seg-pad: 2px;
|
|
1563
|
+
display: inline-grid;
|
|
1564
|
+
flex: none;
|
|
1565
|
+
grid-auto-columns: 1fr;
|
|
1566
|
+
grid-auto-flow: column;
|
|
1567
|
+
margin-left: auto;
|
|
1568
|
+
}
|
|
1569
|
+
:root[data-style='glas'] .nvr-gl-seg--settings .nvr-gl-seg__opt {
|
|
1570
|
+
min-width: 72px;
|
|
1571
|
+
padding: 0 10px;
|
|
1572
|
+
border-inline: 2px solid transparent;
|
|
1573
|
+
}
|
|
1574
|
+
@media (max-width: 480px) {
|
|
1575
|
+
:root[data-style='glas'] .nvr-gl-seg--settings {
|
|
1576
|
+
flex: 1 1 100%;
|
|
1577
|
+
grid-auto-columns: minmax(0, 1fr);
|
|
1578
|
+
}
|
|
1579
|
+
|
|
1580
|
+
:root[data-style='glas'] .nvr-gl-seg--settings .nvr-gl-seg__opt {
|
|
1581
|
+
min-width: 0;
|
|
1582
|
+
padding: 0 2px;
|
|
1583
|
+
}
|
|
1584
|
+
}
|
|
1585
|
+
@media (prefers-reduced-motion: reduce) {
|
|
1586
|
+
:root[data-style='glas'] .nvr-set-card .nvr-accent__slider:active {
|
|
1587
|
+
transform: none;
|
|
1588
|
+
}
|
|
1589
|
+
}
|
|
1590
|
+
@media (forced-colors: active) {
|
|
1591
|
+
:root[data-style='glas'] .nvr-set-card .nvr-set__row::before {
|
|
1592
|
+
forced-color-adjust: none;
|
|
1593
|
+
background: GrayText;
|
|
1594
|
+
}
|
|
1595
|
+
|
|
1596
|
+
:root[data-style='glas'] .nvr-switch {
|
|
1597
|
+
forced-color-adjust: none;
|
|
1598
|
+
border: 1px solid ButtonText;
|
|
1599
|
+
background: Canvas;
|
|
1600
|
+
}
|
|
1601
|
+
|
|
1602
|
+
:root[data-style='glas'] .nvr-switch__thumb {
|
|
1603
|
+
top: 1px;
|
|
1604
|
+
left: 1px;
|
|
1605
|
+
background: ButtonText;
|
|
1606
|
+
box-shadow: none;
|
|
1607
|
+
}
|
|
1608
|
+
|
|
1609
|
+
:root[data-style='glas'] .nvr-switch--on {
|
|
1610
|
+
background: Highlight;
|
|
1611
|
+
}
|
|
1612
|
+
|
|
1613
|
+
:root[data-style='glas'] .nvr-switch--on .nvr-switch__thumb {
|
|
1614
|
+
background: HighlightText;
|
|
1615
|
+
}
|
|
1616
|
+
|
|
1617
|
+
:root[data-style='glas'] .nvr-gl-seg__track {
|
|
1618
|
+
border: 1px solid CanvasText;
|
|
1619
|
+
}
|
|
1620
|
+
|
|
1621
|
+
:root[data-style='glas'] .nvr-gl-seg__lens {
|
|
1622
|
+
border: 2px solid Highlight;
|
|
1623
|
+
}
|
|
1624
|
+
|
|
1625
|
+
:root[data-style='glas'] .nvr-set-card .nvr-accent__slider {
|
|
1626
|
+
forced-color-adjust: none;
|
|
1627
|
+
border: 1px solid CanvasText;
|
|
1628
|
+
}
|
|
1629
|
+
}
|