@svadmin/lite 0.16.11 → 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 +71 -2
- package/dist/components/LiteActivityFeed.svelte +31 -9
- package/dist/components/LiteActivityFeed.svelte.d.ts +6 -0
- package/dist/components/LiteAffix.svelte +29 -0
- package/dist/components/LiteAffix.svelte.d.ts +13 -0
- package/dist/components/LiteAnchor.svelte +38 -0
- package/dist/components/LiteAnchor.svelte.d.ts +14 -0
- package/dist/components/LiteApprovalActionCard.svelte +8 -5
- package/dist/components/LiteApprovalActionCard.svelte.d.ts +2 -0
- package/dist/components/LiteAuditLog.svelte +9 -9
- package/dist/components/LiteAutoComplete.svelte +41 -0
- package/dist/components/LiteAutoComplete.svelte.d.ts +13 -0
- package/dist/components/LiteBackTop.svelte +16 -0
- package/dist/components/LiteBackTop.svelte.d.ts +8 -0
- package/dist/components/LiteBreadcrumbs.svelte +4 -1
- package/dist/components/LiteBreadcrumbs.svelte.d.ts +2 -0
- package/dist/components/LiteCalendar.svelte +124 -0
- package/dist/components/LiteCalendar.svelte.d.ts +20 -0
- package/dist/components/LiteCanvasAnnotation.svelte +13 -13
- package/dist/components/LiteCarousel.svelte +72 -0
- package/dist/components/LiteCarousel.svelte.d.ts +14 -0
- package/dist/components/LiteChatDialog.svelte +8 -8
- package/dist/components/LiteCollapse.svelte +49 -0
- package/dist/components/LiteCollapse.svelte.d.ts +15 -0
- package/dist/components/LiteColumnHeaderFilter.svelte +4 -1
- package/dist/components/LiteColumnHeaderFilter.svelte.d.ts +2 -0
- package/dist/components/LiteColumnSettings.svelte +7 -4
- package/dist/components/LiteColumnSettings.svelte.d.ts +2 -0
- package/dist/components/LiteCommentThread.svelte +113 -0
- package/dist/components/LiteCommentThread.svelte.d.ts +26 -0
- package/dist/components/LiteConfirmDialog.svelte +2 -2
- package/dist/components/LiteCountdown.svelte +49 -0
- package/dist/components/LiteCountdown.svelte.d.ts +10 -0
- package/dist/components/LiteDecisionTable.svelte +14 -14
- package/dist/components/LiteDetailDrawer.svelte +45 -0
- package/dist/components/LiteDetailDrawer.svelte.d.ts +14 -0
- package/dist/components/LiteDraggableRowTable.svelte +5 -2
- package/dist/components/LiteDraggableRowTable.svelte.d.ts +2 -0
- package/dist/components/LiteDrawerForm.svelte +11 -8
- package/dist/components/LiteDrawerForm.svelte.d.ts +2 -0
- package/dist/components/LiteDynamicFormList.svelte +5 -5
- package/dist/components/LiteEditableTable.svelte +5 -2
- package/dist/components/LiteEditableTable.svelte.d.ts +2 -0
- package/dist/components/LiteEmptyState.svelte +11 -4
- package/dist/components/LiteEmptyState.svelte.d.ts +3 -0
- package/dist/components/LiteFilterBuilder.svelte +8 -5
- package/dist/components/LiteFilterBuilder.svelte.d.ts +2 -0
- package/dist/components/LiteFloatButton.svelte +54 -0
- package/dist/components/LiteFloatButton.svelte.d.ts +15 -0
- package/dist/components/LiteGanttChart.svelte +20 -20
- package/dist/components/LiteGrid.svelte +34 -0
- package/dist/components/LiteGrid.svelte.d.ts +11 -0
- package/dist/components/LiteImage.svelte +54 -0
- package/dist/components/LiteImage.svelte.d.ts +14 -0
- package/dist/components/LiteImageCropper.svelte +7 -4
- package/dist/components/LiteImageCropper.svelte.d.ts +2 -0
- package/dist/components/LiteImagePreview.svelte +36 -0
- package/dist/components/LiteImagePreview.svelte.d.ts +13 -0
- package/dist/components/LiteImportWizard.svelte +7 -7
- package/dist/components/LiteItemList.svelte +50 -0
- package/dist/components/LiteItemList.svelte.d.ts +15 -0
- package/dist/components/LiteJsonSchemaForm.svelte +10 -7
- package/dist/components/LiteJsonSchemaForm.svelte.d.ts +2 -0
- package/dist/components/LiteKanbanBoard.svelte +19 -19
- package/dist/components/LiteLayout.svelte +18 -6
- package/dist/components/LiteLayout.svelte.d.ts +8 -0
- package/dist/components/LiteLink.svelte +32 -0
- package/dist/components/LiteLink.svelte.d.ts +11 -0
- package/dist/components/LiteLogin.svelte +9 -2
- package/dist/components/LiteLogin.svelte.d.ts +2 -0
- package/dist/components/LiteMasterDetailView.svelte +13 -10
- package/dist/components/LiteMasterDetailView.svelte.d.ts +2 -0
- package/dist/components/LiteMediaLibraryModal.svelte +8 -5
- package/dist/components/LiteMediaLibraryModal.svelte.d.ts +2 -0
- package/dist/components/LiteMediaThumbnail.svelte +3 -3
- package/dist/components/LiteMentionsInput.svelte +9 -9
- package/dist/components/LiteMenu.svelte +22 -0
- package/dist/components/LiteMenu.svelte.d.ts +12 -0
- package/dist/components/LiteMenuList.svelte +55 -0
- package/dist/components/LiteMenuList.svelte.d.ts +17 -0
- package/dist/components/LiteModalForm.svelte +9 -6
- package/dist/components/LiteModalForm.svelte.d.ts +2 -0
- package/dist/components/LiteMultiTabKeepAlive.svelte +6 -6
- package/dist/components/LiteNotificationCenter.svelte +85 -0
- package/dist/components/LiteNotificationCenter.svelte.d.ts +22 -0
- package/dist/components/LiteOfflineSyncBanner.svelte +6 -6
- package/dist/components/LiteOtpInput.svelte +50 -0
- package/dist/components/LiteOtpInput.svelte.d.ts +15 -0
- package/dist/components/LitePageHeader.svelte +34 -0
- package/dist/components/LitePageHeader.svelte.d.ts +13 -0
- package/dist/components/LitePagination.svelte +10 -2
- package/dist/components/LitePagination.svelte.d.ts +2 -0
- package/dist/components/LitePdfDocumentViewer.svelte +14 -14
- package/dist/components/LitePermissionMatrix.svelte +8 -8
- package/dist/components/LitePivotTable.svelte +11 -11
- package/dist/components/LitePopconfirm.svelte +49 -0
- package/dist/components/LitePopconfirm.svelte.d.ts +14 -0
- package/dist/components/LitePresenceAvatarGroup.svelte +8 -5
- package/dist/components/LitePresenceAvatarGroup.svelte.d.ts +2 -0
- package/dist/components/LitePrintableBill.svelte +12 -9
- package/dist/components/LitePrintableBill.svelte.d.ts +2 -0
- package/dist/components/LiteProgress.svelte +46 -0
- package/dist/components/LiteProgress.svelte.d.ts +12 -0
- package/dist/components/LiteQRCode.svelte +62 -0
- package/dist/components/LiteQRCode.svelte.d.ts +14 -0
- package/dist/components/LiteResizeBox.svelte +34 -0
- package/dist/components/LiteResizeBox.svelte.d.ts +12 -0
- package/dist/components/LiteResult.svelte +52 -0
- package/dist/components/LiteResult.svelte.d.ts +14 -0
- package/dist/components/LiteRowActions.svelte +36 -0
- package/dist/components/LiteRowActions.svelte.d.ts +17 -0
- package/dist/components/LiteSensitiveDataMask.svelte +4 -1
- package/dist/components/LiteSensitiveDataMask.svelte.d.ts +2 -0
- package/dist/components/LiteShow.svelte +1 -1
- package/dist/components/LiteShowField.svelte +2 -2
- package/dist/components/LiteSignaturePad.svelte +9 -9
- package/dist/components/LiteSkeleton.svelte +100 -0
- package/dist/components/LiteSkeleton.svelte.d.ts +19 -0
- package/dist/components/LiteSpace.svelte +31 -0
- package/dist/components/LiteSpace.svelte.d.ts +12 -0
- package/dist/components/LiteSpin.svelte +27 -0
- package/dist/components/LiteSpin.svelte.d.ts +10 -0
- package/dist/components/LiteSplitPaneLayout.svelte +18 -6
- package/dist/components/LiteSplitPaneLayout.svelte.d.ts +8 -0
- package/dist/components/LiteSpreadsheetView.svelte +8 -8
- package/dist/components/LiteStatistic.svelte +63 -0
- package/dist/components/LiteStatistic.svelte.d.ts +15 -0
- package/dist/components/LiteStatsCard.svelte +5 -2
- package/dist/components/LiteStatsCard.svelte.d.ts +2 -0
- package/dist/components/LiteStatusBadge.svelte +33 -0
- package/dist/components/LiteStatusBadge.svelte.d.ts +12 -0
- package/dist/components/LiteStatusTabs.svelte +35 -0
- package/dist/components/LiteStatusTabs.svelte.d.ts +14 -0
- package/dist/components/LiteStepForm.svelte +14 -11
- package/dist/components/LiteStepForm.svelte.d.ts +2 -0
- package/dist/components/LiteSteps.svelte +64 -0
- package/dist/components/LiteSteps.svelte.d.ts +18 -0
- package/dist/components/LiteTable.svelte +5 -2
- package/dist/components/LiteTable.svelte.d.ts +2 -0
- package/dist/components/LiteTableSummary.svelte +8 -5
- package/dist/components/LiteTableSummary.svelte.d.ts +2 -0
- package/dist/components/LiteTabs.svelte +30 -20
- package/dist/components/LiteTabs.svelte.d.ts +11 -2
- package/dist/components/LiteTag.svelte +31 -0
- package/dist/components/LiteTag.svelte.d.ts +13 -0
- package/dist/components/LiteTimeline.svelte +48 -0
- package/dist/components/LiteTimeline.svelte.d.ts +17 -0
- package/dist/components/LiteTour.svelte +54 -0
- package/dist/components/LiteTour.svelte.d.ts +15 -0
- package/dist/components/LiteTransfer.svelte +9 -6
- package/dist/components/LiteTransfer.svelte.d.ts +2 -0
- package/dist/components/LiteTree.svelte +48 -0
- package/dist/components/LiteTree.svelte.d.ts +17 -0
- package/dist/components/LiteTreeTable.svelte +1 -1
- package/dist/components/LiteTwoFactorStepper.svelte +53 -0
- package/dist/components/LiteTwoFactorStepper.svelte.d.ts +16 -0
- package/dist/components/LiteVersionDiffViewer.svelte +16 -13
- package/dist/components/LiteVersionDiffViewer.svelte.d.ts +2 -0
- package/dist/components/LiteVideoPlayer.svelte +67 -0
- package/dist/components/LiteVideoPlayer.svelte.d.ts +22 -0
- package/dist/components/LiteVirtualTable.svelte +1 -1
- package/dist/components/advanced/LiteAutoSaveIndicator.svelte +42 -13
- package/dist/components/advanced/LiteAutoSaveIndicator.svelte.d.ts +10 -4
- package/dist/components/advanced/LiteDraggableHeader.svelte +2 -2
- package/dist/components/advanced/LiteDrawerForm.svelte +4 -1
- package/dist/components/advanced/LiteDrawerForm.svelte.d.ts +2 -0
- package/dist/components/advanced/LiteInlineEdit.svelte +1 -1
- package/dist/components/advanced/LiteModalForm.svelte +4 -1
- package/dist/components/advanced/LiteModalForm.svelte.d.ts +2 -0
- package/dist/components/advanced/LiteToast.svelte +3 -3
- package/dist/components/advanced/LiteUndoableNotification.svelte +1 -1
- package/dist/components/compatibility/LiteRealtimeStatus.svelte +41 -2
- package/dist/components/compatibility/LiteRealtimeStatus.svelte.d.ts +15 -0
- package/dist/components/fields/LiteBooleanField.svelte +4 -2
- package/dist/components/fields/LiteBooleanField.svelte.d.ts +2 -0
- package/dist/components/fields/LiteCascader.svelte +5 -2
- package/dist/components/fields/LiteCascader.svelte.d.ts +2 -0
- package/dist/components/fields/LiteDateField.svelte +39 -9
- package/dist/components/fields/LiteDateField.svelte.d.ts +2 -0
- package/dist/components/fields/LiteDateRangeField.svelte +1 -1
- package/dist/components/fields/LiteImageField.svelte +6 -2
- package/dist/components/fields/LiteImageField.svelte.d.ts +2 -0
- package/dist/components/fields/LiteJsonField.svelte +1 -1
- package/dist/components/fields/LiteMarkdownField.svelte +49 -3
- package/dist/components/fields/LiteMarkdownField.svelte.d.ts +5 -0
- package/dist/components/fields/LiteNumberField.svelte +5 -3
- package/dist/components/fields/LiteNumberField.svelte.d.ts +2 -0
- package/dist/components/fields/LiteRichTextField.svelte +49 -12
- package/dist/components/fields/LiteRichTextField.svelte.d.ts +3 -0
- package/dist/components/fields/LiteSelectField.svelte +5 -3
- package/dist/components/fields/LiteSelectField.svelte.d.ts +2 -0
- package/dist/components/fields/LiteTagField.svelte +38 -15
- package/dist/components/fields/LiteTagField.svelte.d.ts +2 -0
- package/dist/components/fields/LiteTextField.svelte +26 -5
- package/dist/components/fields/LiteTextField.svelte.d.ts +2 -0
- package/dist/components/fields/LiteTreeSelect.svelte +5 -2
- package/dist/components/fields/LiteTreeSelect.svelte.d.ts +2 -0
- package/dist/components/fields/LiteUrlField.svelte +5 -3
- package/dist/components/fields/LiteUrlField.svelte.d.ts +2 -0
- package/dist/components/layout/LiteAuthenticated.svelte +2 -2
- package/dist/components/layout/LiteCanAccess.svelte +1 -1
- package/dist/components/layout/LiteErrorComponent.svelte +4 -4
- package/dist/components/layout/LiteHeader.svelte +2 -2
- package/dist/components/layout/LiteSidebar.svelte +6 -3
- package/dist/components/layout/LiteSidebar.svelte.d.ts +2 -0
- package/dist/components/pages/LiteCreatePage.svelte +4 -1
- package/dist/components/pages/LiteCreatePage.svelte.d.ts +2 -0
- package/dist/components/pages/LiteEditPage.svelte +4 -1
- package/dist/components/pages/LiteEditPage.svelte.d.ts +2 -0
- package/dist/components/pages/LiteForgotPasswordPage.svelte +7 -7
- package/dist/components/pages/LiteListPage.svelte +6 -3
- package/dist/components/pages/LiteListPage.svelte.d.ts +2 -0
- package/dist/components/pages/LiteProfilePage.svelte +2 -2
- package/dist/components/pages/LiteRegisterPage.svelte +6 -6
- package/dist/components/pages/LiteShowPage.svelte +6 -3
- package/dist/components/pages/LiteShowPage.svelte.d.ts +2 -0
- package/dist/components/pages/LiteUpdatePasswordPage.svelte +4 -4
- package/dist/components/widgets/LiteAnomalyBadge.svelte +6 -3
- package/dist/components/widgets/LiteAnomalyBadge.svelte.d.ts +2 -0
- package/dist/components/widgets/LiteAreaChart.svelte +20 -0
- package/dist/components/widgets/LiteAreaChart.svelte.d.ts +10 -0
- package/dist/components/widgets/LiteBarChart.svelte +6 -6
- package/dist/components/widgets/LiteChartSvg.svelte +102 -0
- package/dist/components/widgets/LiteChartSvg.svelte.d.ts +10 -0
- package/dist/components/widgets/LiteChartTable.svelte +44 -0
- package/dist/components/widgets/LiteChartTable.svelte.d.ts +10 -0
- package/dist/components/widgets/LiteDonutChart.svelte +20 -0
- package/dist/components/widgets/LiteDonutChart.svelte.d.ts +10 -0
- package/dist/components/widgets/LiteFunnelChart.svelte +20 -0
- package/dist/components/widgets/LiteFunnelChart.svelte.d.ts +10 -0
- package/dist/components/widgets/LiteGaugeChart.svelte +20 -0
- package/dist/components/widgets/LiteGaugeChart.svelte.d.ts +10 -0
- package/dist/components/widgets/LiteHeatmapChart.svelte +20 -0
- package/dist/components/widgets/LiteHeatmapChart.svelte.d.ts +10 -0
- package/dist/components/widgets/LiteInsightCard.svelte +35 -13
- package/dist/components/widgets/LiteInsightCard.svelte.d.ts +7 -4
- package/dist/components/widgets/LiteLineChart.svelte +13 -10
- package/dist/components/widgets/LiteLineChart.svelte.d.ts +0 -5
- package/dist/components/widgets/LitePieChart.svelte +11 -9
- package/dist/components/widgets/LitePieChart.svelte.d.ts +0 -5
- package/dist/components/widgets/LiteRadarChart.svelte +20 -0
- package/dist/components/widgets/LiteRadarChart.svelte.d.ts +10 -0
- package/dist/components/widgets/LiteRoseChart.svelte +20 -0
- package/dist/components/widgets/LiteRoseChart.svelte.d.ts +10 -0
- package/dist/components/widgets/LiteScatterChart.svelte +20 -0
- package/dist/components/widgets/LiteScatterChart.svelte.d.ts +10 -0
- package/dist/components/widgets/LiteWaterfallChart.svelte +20 -0
- package/dist/components/widgets/LiteWaterfallChart.svelte.d.ts +10 -0
- package/dist/components/widgets/chart-geometry.d.ts +65 -0
- package/dist/components/widgets/chart-geometry.js +229 -0
- package/dist/components/widgets/index.d.ts +10 -0
- package/dist/components/widgets/index.js +10 -0
- package/dist/index.d.ts +40 -0
- package/dist/index.js +47 -0
- package/dist/lite-code-theme.css +139 -0
- package/dist/lite.css +234 -127
- package/dist/rich-content.d.ts +47 -0
- package/dist/rich-content.js +498 -0
- package/dist/schema-generator.js +3 -1
- package/dist/server-adapter.js +6 -11
- package/dist/value-normalization.d.ts +4 -0
- package/dist/value-normalization.js +13 -0
- package/package.json +18 -4
|
@@ -102,7 +102,7 @@
|
|
|
102
102
|
<style>
|
|
103
103
|
.sv-lite-decision-container {
|
|
104
104
|
display: block;
|
|
105
|
-
border: 1px solid #
|
|
105
|
+
border: 1px solid #E5E6EB;
|
|
106
106
|
border-radius: 6px;
|
|
107
107
|
padding: 12px;
|
|
108
108
|
background-color: #ffffff;
|
|
@@ -112,11 +112,11 @@
|
|
|
112
112
|
.sv-lite-decision-header {
|
|
113
113
|
margin-bottom: 10px;
|
|
114
114
|
font-size: 13px;
|
|
115
|
-
color: #
|
|
115
|
+
color: #1D2129;
|
|
116
116
|
}
|
|
117
117
|
.sv-lite-hit-policy {
|
|
118
118
|
font-size: 10px;
|
|
119
|
-
color: #
|
|
119
|
+
color: #4E5969;
|
|
120
120
|
margin-left: 6px;
|
|
121
121
|
}
|
|
122
122
|
.sv-lite-decision-table {
|
|
@@ -125,42 +125,42 @@
|
|
|
125
125
|
font-family: monospace;
|
|
126
126
|
}
|
|
127
127
|
.sv-lite-decision-table th, .sv-lite-decision-table td {
|
|
128
|
-
border: 1px solid #
|
|
128
|
+
border: 1px solid #E5E6EB;
|
|
129
129
|
padding: 4px 6px;
|
|
130
130
|
}
|
|
131
131
|
.sv-lite-th-idx, .sv-lite-td-idx {
|
|
132
|
-
background-color: #
|
|
132
|
+
background-color: #F2F3F5;
|
|
133
133
|
text-align: center;
|
|
134
134
|
width: 28px;
|
|
135
135
|
font-size: 10px;
|
|
136
136
|
}
|
|
137
137
|
.sv-lite-th-cond {
|
|
138
|
-
background-color: #
|
|
139
|
-
color: #
|
|
138
|
+
background-color: #E8F3FF;
|
|
139
|
+
color: #0E42D2;
|
|
140
140
|
text-align: center;
|
|
141
141
|
font-weight: bold;
|
|
142
142
|
}
|
|
143
143
|
.sv-lite-th-act {
|
|
144
|
-
background-color: #
|
|
145
|
-
color: #
|
|
144
|
+
background-color: #E8FFEA;
|
|
145
|
+
color: #009A29;
|
|
146
146
|
text-align: center;
|
|
147
147
|
font-weight: bold;
|
|
148
148
|
}
|
|
149
149
|
.sv-lite-th-sub {
|
|
150
|
-
background-color: #
|
|
151
|
-
color: #
|
|
150
|
+
background-color: #F7F8FA;
|
|
151
|
+
color: #4E5969;
|
|
152
152
|
font-weight: 600;
|
|
153
153
|
}
|
|
154
154
|
.sv-lite-rule-input {
|
|
155
155
|
width: 100%;
|
|
156
|
-
border: 1px solid #
|
|
156
|
+
border: 1px solid #E5E6EB;
|
|
157
157
|
padding: 3px;
|
|
158
158
|
font-size: 11px;
|
|
159
159
|
box-sizing: border-box;
|
|
160
160
|
}
|
|
161
161
|
.sv-lite-act-input {
|
|
162
162
|
font-weight: bold;
|
|
163
|
-
color: #
|
|
163
|
+
color: #0E42D2;
|
|
164
164
|
}
|
|
165
165
|
.sv-lite-decision-actions {
|
|
166
166
|
margin-top: 10px;
|
|
@@ -168,7 +168,7 @@
|
|
|
168
168
|
}
|
|
169
169
|
.sv-lite-save-btn {
|
|
170
170
|
padding: 5px 12px;
|
|
171
|
-
background-color: #
|
|
171
|
+
background-color: #165DFF;
|
|
172
172
|
color: #ffffff;
|
|
173
173
|
border: none;
|
|
174
174
|
border-radius: 3px;
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import type { Snippet } from 'svelte';
|
|
3
|
+
|
|
4
|
+
interface Props {
|
|
5
|
+
id: string;
|
|
6
|
+
title: string;
|
|
7
|
+
description?: string;
|
|
8
|
+
open?: boolean;
|
|
9
|
+
closeHref?: string;
|
|
10
|
+
children: Snippet;
|
|
11
|
+
/** Caller class merged with the built-in class list. */
|
|
12
|
+
class?: string;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
let {
|
|
16
|
+
id,
|
|
17
|
+
title,
|
|
18
|
+
description,
|
|
19
|
+
open = false,
|
|
20
|
+
closeHref = '#',
|
|
21
|
+
children,
|
|
22
|
+
class: className = '',
|
|
23
|
+
}: Props = $props();
|
|
24
|
+
</script>
|
|
25
|
+
|
|
26
|
+
<div class="lite-detail-drawer {className}" data-open={open || undefined}>
|
|
27
|
+
<a class="lite-btn lite-btn-sm" href={`#${id}`}>Details</a>
|
|
28
|
+
<aside class="lite-detail-drawer__panel" id={id} aria-label={title}>
|
|
29
|
+
<header>
|
|
30
|
+
<h2>{title}</h2>
|
|
31
|
+
<a href={closeHref} aria-label="Close details">×</a>
|
|
32
|
+
</header>
|
|
33
|
+
{#if description}<p class="lite-muted">{description}</p>{/if}
|
|
34
|
+
{@render children()}
|
|
35
|
+
</aside>
|
|
36
|
+
</div>
|
|
37
|
+
|
|
38
|
+
<style>
|
|
39
|
+
.lite-detail-drawer { display: inline-block; }
|
|
40
|
+
.lite-detail-drawer__panel { display: none; position: fixed; z-index: 40; top: 0; right: 0; bottom: 0; width: 28rem; max-width: 100vw; overflow: auto; padding: 20px; border-left: 1px solid #E5E6EB; background: #fff; box-shadow: -12px 0 32px rgba(29, 33, 41, 0.14); }
|
|
41
|
+
.lite-detail-drawer__panel:target, .lite-detail-drawer[data-open] .lite-detail-drawer__panel { display: block; }
|
|
42
|
+
.lite-detail-drawer__panel header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
|
|
43
|
+
.lite-detail-drawer__panel h2 { margin: 0; color: #1D2129; font-size: 18px; }
|
|
44
|
+
.lite-detail-drawer__panel header a { margin-left: 12px; color: #4E5969; font-size: 24px; line-height: 1; text-decoration: none; }
|
|
45
|
+
</style>
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { Snippet } from 'svelte';
|
|
2
|
+
interface Props {
|
|
3
|
+
id: string;
|
|
4
|
+
title: string;
|
|
5
|
+
description?: string;
|
|
6
|
+
open?: boolean;
|
|
7
|
+
closeHref?: string;
|
|
8
|
+
children: Snippet;
|
|
9
|
+
/** Caller class merged with the built-in class list. */
|
|
10
|
+
class?: string;
|
|
11
|
+
}
|
|
12
|
+
declare const LiteDetailDrawer: import("svelte").Component<Props, {}, "">;
|
|
13
|
+
type LiteDetailDrawer = ReturnType<typeof LiteDetailDrawer>;
|
|
14
|
+
export default LiteDetailDrawer;
|
|
@@ -10,6 +10,8 @@
|
|
|
10
10
|
action?: string;
|
|
11
11
|
method?: 'get' | 'post' | 'dialog' | 'GET' | 'POST' | 'DIALOG' | null;
|
|
12
12
|
rowKey?: string;
|
|
13
|
+
/** Caller class merged with the built-in class list. */
|
|
14
|
+
class?: string;
|
|
13
15
|
}
|
|
14
16
|
|
|
15
17
|
let {
|
|
@@ -18,10 +20,11 @@
|
|
|
18
20
|
action = '',
|
|
19
21
|
method = 'POST',
|
|
20
22
|
rowKey = 'id',
|
|
23
|
+
class: className = '',
|
|
21
24
|
}: Props = $props();
|
|
22
25
|
</script>
|
|
23
26
|
|
|
24
|
-
<div class="lite-sortable-table-card">
|
|
27
|
+
<div class="lite-sortable-table-card {className}">
|
|
25
28
|
<form {action} {method}>
|
|
26
29
|
<table class="lite-table">
|
|
27
30
|
<thead>
|
|
@@ -57,7 +60,7 @@
|
|
|
57
60
|
<style>
|
|
58
61
|
.lite-sortable-table-card {
|
|
59
62
|
background: #ffffff;
|
|
60
|
-
border: 1px solid #
|
|
63
|
+
border: 1px solid #E5E6EB;
|
|
61
64
|
border-radius: 6px;
|
|
62
65
|
padding: 12px;
|
|
63
66
|
margin-bottom: 16px;
|
|
@@ -8,6 +8,8 @@ interface Props {
|
|
|
8
8
|
action?: string;
|
|
9
9
|
method?: 'get' | 'post' | 'dialog' | 'GET' | 'POST' | 'DIALOG' | null;
|
|
10
10
|
rowKey?: string;
|
|
11
|
+
/** Caller class merged with the built-in class list. */
|
|
12
|
+
class?: string;
|
|
11
13
|
}
|
|
12
14
|
declare const LiteDraggableRowTable: import("svelte").Component<Props, {}, "">;
|
|
13
15
|
type LiteDraggableRowTable = ReturnType<typeof LiteDraggableRowTable>;
|
|
@@ -9,6 +9,8 @@
|
|
|
9
9
|
submitText?: string;
|
|
10
10
|
cancelText?: string;
|
|
11
11
|
children?: Snippet;
|
|
12
|
+
/** Caller class merged with the built-in class list. */
|
|
13
|
+
class?: string;
|
|
12
14
|
}
|
|
13
15
|
|
|
14
16
|
let {
|
|
@@ -19,10 +21,11 @@
|
|
|
19
21
|
submitText = 'Save',
|
|
20
22
|
cancelText = 'Cancel',
|
|
21
23
|
children,
|
|
24
|
+
class: className = '',
|
|
22
25
|
}: Props = $props();
|
|
23
26
|
</script>
|
|
24
27
|
|
|
25
|
-
<div class="lite-drawer-card">
|
|
28
|
+
<div class="lite-drawer-card {className}">
|
|
26
29
|
<div class="lite-drawer-header">
|
|
27
30
|
<h3 class="lite-drawer-title">{title}</h3>
|
|
28
31
|
{#if description}
|
|
@@ -51,26 +54,26 @@
|
|
|
51
54
|
<style>
|
|
52
55
|
.lite-drawer-card {
|
|
53
56
|
padding: 16px;
|
|
54
|
-
background: #
|
|
55
|
-
border: 1px solid #
|
|
56
|
-
border-left: 4px solid #
|
|
57
|
+
background: #F7F8FA;
|
|
58
|
+
border: 1px solid #E5E6EB;
|
|
59
|
+
border-left: 4px solid #165DFF;
|
|
57
60
|
border-radius: 4px;
|
|
58
61
|
margin-bottom: 16px;
|
|
59
62
|
}
|
|
60
63
|
.lite-drawer-header {
|
|
61
64
|
padding-bottom: 10px;
|
|
62
|
-
border-bottom: 1px solid #
|
|
65
|
+
border-bottom: 1px solid #E5E6EB;
|
|
63
66
|
margin-bottom: 12px;
|
|
64
67
|
}
|
|
65
68
|
.lite-drawer-title {
|
|
66
69
|
margin: 0;
|
|
67
70
|
font-size: 14px;
|
|
68
|
-
color: #
|
|
71
|
+
color: #1D2129;
|
|
69
72
|
}
|
|
70
73
|
.lite-drawer-desc {
|
|
71
74
|
margin: 4px 0 0 0;
|
|
72
75
|
font-size: 12px;
|
|
73
|
-
color: #
|
|
76
|
+
color: #4E5969;
|
|
74
77
|
}
|
|
75
78
|
.lite-drawer-body {
|
|
76
79
|
margin-bottom: 16px;
|
|
@@ -80,6 +83,6 @@
|
|
|
80
83
|
display: flex;
|
|
81
84
|
justify-content: flex-end;
|
|
82
85
|
padding-top: 12px;
|
|
83
|
-
border-top: 1px solid #
|
|
86
|
+
border-top: 1px solid #E5E6EB;
|
|
84
87
|
}
|
|
85
88
|
</style>
|
|
@@ -7,6 +7,8 @@ interface Props {
|
|
|
7
7
|
submitText?: string;
|
|
8
8
|
cancelText?: string;
|
|
9
9
|
children?: Snippet;
|
|
10
|
+
/** Caller class merged with the built-in class list. */
|
|
11
|
+
class?: string;
|
|
10
12
|
}
|
|
11
13
|
declare const LiteDrawerForm: import("svelte").Component<Props, {}, "">;
|
|
12
14
|
type LiteDrawerForm = ReturnType<typeof LiteDrawerForm>;
|
|
@@ -121,7 +121,7 @@
|
|
|
121
121
|
|
|
122
122
|
<style>
|
|
123
123
|
.lite-dynamic-form-list {
|
|
124
|
-
border: 1px solid #
|
|
124
|
+
border: 1px solid #E5E6EB;
|
|
125
125
|
border-radius: 6px;
|
|
126
126
|
padding: 14px;
|
|
127
127
|
background-color: #fafafa;
|
|
@@ -139,7 +139,7 @@
|
|
|
139
139
|
}
|
|
140
140
|
.lite-dynamic-item-card {
|
|
141
141
|
background: #ffffff;
|
|
142
|
-
border: 1px solid #
|
|
142
|
+
border: 1px solid #E5E6EB;
|
|
143
143
|
border-radius: 4px;
|
|
144
144
|
padding: 12px;
|
|
145
145
|
margin-bottom: 10px;
|
|
@@ -149,7 +149,7 @@
|
|
|
149
149
|
justify-content: space-between;
|
|
150
150
|
align-items: center;
|
|
151
151
|
margin-bottom: 8px;
|
|
152
|
-
border-bottom: 1px dashed #
|
|
152
|
+
border-bottom: 1px dashed #E5E6EB;
|
|
153
153
|
padding-bottom: 6px;
|
|
154
154
|
}
|
|
155
155
|
.lite-dynamic-item-tools {
|
|
@@ -161,9 +161,9 @@
|
|
|
161
161
|
.lite-empty-box {
|
|
162
162
|
text-align: center;
|
|
163
163
|
padding: 24px 12px;
|
|
164
|
-
color: #
|
|
164
|
+
color: #4E5969;
|
|
165
165
|
background: #ffffff;
|
|
166
|
-
border: 1px dashed #
|
|
166
|
+
border: 1px dashed #E5E6EB;
|
|
167
167
|
border-radius: 4px;
|
|
168
168
|
}
|
|
169
169
|
</style>
|
|
@@ -12,6 +12,8 @@
|
|
|
12
12
|
action?: string;
|
|
13
13
|
method?: 'get' | 'post' | 'dialog' | 'GET' | 'POST' | 'DIALOG' | null;
|
|
14
14
|
rowKey?: string;
|
|
15
|
+
/** Caller class merged with the built-in class list. */
|
|
16
|
+
class?: string;
|
|
15
17
|
}
|
|
16
18
|
|
|
17
19
|
let {
|
|
@@ -20,10 +22,11 @@
|
|
|
20
22
|
action = '',
|
|
21
23
|
method = 'POST',
|
|
22
24
|
rowKey = 'id',
|
|
25
|
+
class: className = '',
|
|
23
26
|
}: Props = $props();
|
|
24
27
|
</script>
|
|
25
28
|
|
|
26
|
-
<div class="lite-editable-table-card">
|
|
29
|
+
<div class="lite-editable-table-card {className}">
|
|
27
30
|
<form {action} {method}>
|
|
28
31
|
<table class="lite-table">
|
|
29
32
|
<thead>
|
|
@@ -71,7 +74,7 @@
|
|
|
71
74
|
<style>
|
|
72
75
|
.lite-editable-table-card {
|
|
73
76
|
background: #ffffff;
|
|
74
|
-
border: 1px solid #
|
|
77
|
+
border: 1px solid #E5E6EB;
|
|
75
78
|
border-radius: 6px;
|
|
76
79
|
padding: 12px;
|
|
77
80
|
margin-bottom: 16px;
|
|
@@ -13,6 +13,8 @@ interface Props {
|
|
|
13
13
|
action?: string;
|
|
14
14
|
method?: 'get' | 'post' | 'dialog' | 'GET' | 'POST' | 'DIALOG' | null;
|
|
15
15
|
rowKey?: string;
|
|
16
|
+
/** Caller class merged with the built-in class list. */
|
|
17
|
+
class?: string;
|
|
16
18
|
}
|
|
17
19
|
declare const LiteEditableTable: import("svelte").Component<Props, {}, "">;
|
|
18
20
|
type LiteEditableTable = ReturnType<typeof LiteEditableTable>;
|
|
@@ -10,6 +10,9 @@
|
|
|
10
10
|
description?: string;
|
|
11
11
|
/** Optional HTML entity or text icon */
|
|
12
12
|
icon?: string;
|
|
13
|
+
/** Optional illustration URL; mirrors the full EmptyState image API. */
|
|
14
|
+
imageUrl?: string;
|
|
15
|
+
imageAlt?: string;
|
|
13
16
|
actionLabel?: string;
|
|
14
17
|
actionUrl?: string;
|
|
15
18
|
}
|
|
@@ -18,18 +21,22 @@
|
|
|
18
21
|
title,
|
|
19
22
|
description,
|
|
20
23
|
icon,
|
|
24
|
+
imageUrl,
|
|
25
|
+
imageAlt,
|
|
21
26
|
actionLabel,
|
|
22
27
|
actionUrl,
|
|
23
28
|
}: Props = $props();
|
|
24
29
|
</script>
|
|
25
30
|
|
|
26
31
|
<div class="lite-empty-state lite-card" style="text-align:center;padding:48px 24px;">
|
|
27
|
-
{#if
|
|
28
|
-
<
|
|
32
|
+
{#if imageUrl}
|
|
33
|
+
<img src={imageUrl} alt={imageAlt ?? ''} loading="lazy" style="display:block;width:96px;height:96px;object-fit:contain;margin:0 auto 16px auto;" />
|
|
34
|
+
{:else if icon}
|
|
35
|
+
<div style="font-size:32px;color:#86909C;margin-bottom:16px;">{icon}</div>
|
|
29
36
|
{/if}
|
|
30
|
-
<h3 style="font-size:16px;font-weight:600;color:#
|
|
37
|
+
<h3 style="font-size:16px;font-weight:600;color:#1D2129;margin:0 0 8px 0;">{title}</h3>
|
|
31
38
|
{#if description}
|
|
32
|
-
<p style="font-size:14px;color:#
|
|
39
|
+
<p style="font-size:14px;color:#4E5969;margin:0 0 24px 0;">{description}</p>
|
|
33
40
|
{/if}
|
|
34
41
|
{#if actionLabel && actionUrl}
|
|
35
42
|
<a href={actionUrl} class="lite-btn lite-btn-primary">
|
|
@@ -8,6 +8,9 @@ interface Props {
|
|
|
8
8
|
description?: string;
|
|
9
9
|
/** Optional HTML entity or text icon */
|
|
10
10
|
icon?: string;
|
|
11
|
+
/** Optional illustration URL; mirrors the full EmptyState image API. */
|
|
12
|
+
imageUrl?: string;
|
|
13
|
+
imageAlt?: string;
|
|
11
14
|
actionLabel?: string;
|
|
12
15
|
actionUrl?: string;
|
|
13
16
|
}
|
|
@@ -23,6 +23,8 @@
|
|
|
23
23
|
method?: 'GET' | 'POST';
|
|
24
24
|
disabled?: boolean;
|
|
25
25
|
onApply?: (filters: Filter[]) => void;
|
|
26
|
+
/** Caller class merged with the built-in class list. */
|
|
27
|
+
class?: string;
|
|
26
28
|
}
|
|
27
29
|
|
|
28
30
|
let {
|
|
@@ -32,6 +34,7 @@
|
|
|
32
34
|
method = 'GET',
|
|
33
35
|
disabled = false,
|
|
34
36
|
onApply,
|
|
37
|
+
class: className = '',
|
|
35
38
|
}: Props = $props();
|
|
36
39
|
let validationError = $state<string | undefined>();
|
|
37
40
|
|
|
@@ -105,7 +108,7 @@
|
|
|
105
108
|
|
|
106
109
|
</script>
|
|
107
110
|
|
|
108
|
-
<div class="lite-filter-builder lite-form-group">
|
|
111
|
+
<div class="lite-filter-builder lite-form-group {className}">
|
|
109
112
|
<div class="lite-filter-header">
|
|
110
113
|
<strong>{t('common.filters') || '高级多条件筛选'}</strong>
|
|
111
114
|
<button type="submit" form={formId} class="lite-btn lite-btn-primary lite-btn-sm" disabled={disabled}>
|
|
@@ -204,15 +207,15 @@
|
|
|
204
207
|
</div>
|
|
205
208
|
|
|
206
209
|
<style>
|
|
207
|
-
.lite-filter-builder { border: 1px solid #
|
|
210
|
+
.lite-filter-builder { border: 1px solid #E5E6EB; border-radius: 6px; padding: 14px; background: #F7F8FA; margin-bottom: 16px; }
|
|
208
211
|
.lite-filter-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
|
|
209
|
-
.lite-filter-group { border: 1px solid #
|
|
210
|
-
.lite-filter-row { display: flex; align-items: center; padding: 8px; border: 1px solid #
|
|
212
|
+
.lite-filter-group { border: 1px solid #E5E6EB; border-radius: 4px; padding: 10px; margin-bottom: 8px; background: #fff; }
|
|
213
|
+
.lite-filter-row { display: flex; align-items: center; padding: 8px; border: 1px solid #E5E6EB; border-radius: 4px; margin-bottom: 8px; background: #fff; }
|
|
211
214
|
.lite-filter-row > * { min-width: 120px; flex: 1; }
|
|
212
215
|
.lite-filter-row > * + * { margin-left: 8px; }
|
|
213
216
|
.lite-filter-row .lite-btn { flex: 0 0 auto; }
|
|
214
217
|
.lite-filter-values { display: flex; flex-wrap: wrap; min-width: 0; }
|
|
215
218
|
.lite-filter-values > * { width: 160px; max-width: 100%; box-sizing: border-box; margin: 0 8px 8px 0; }
|
|
216
|
-
.lite-hint { color: #
|
|
219
|
+
.lite-hint { color: #4E5969; font-size: 12px; }
|
|
217
220
|
.lite-btn { margin-right: 6px; }
|
|
218
221
|
</style>
|
|
@@ -12,6 +12,8 @@ interface Props {
|
|
|
12
12
|
method?: 'GET' | 'POST';
|
|
13
13
|
disabled?: boolean;
|
|
14
14
|
onApply?: (filters: Filter[]) => void;
|
|
15
|
+
/** Caller class merged with the built-in class list. */
|
|
16
|
+
class?: string;
|
|
15
17
|
}
|
|
16
18
|
declare const LiteFilterBuilder: import("svelte").Component<Props, {}, "">;
|
|
17
19
|
type LiteFilterBuilder = ReturnType<typeof LiteFilterBuilder>;
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
interface Props {
|
|
3
|
+
href?: string;
|
|
4
|
+
label?: string;
|
|
5
|
+
description?: string;
|
|
6
|
+
icon?: string;
|
|
7
|
+
badge?: string | number;
|
|
8
|
+
position?: 'bottom-right' | 'bottom-left' | 'top-right' | 'top-left';
|
|
9
|
+
target?: string;
|
|
10
|
+
ariaLabel?: string;
|
|
11
|
+
/** Caller class merged with the built-in class list. */
|
|
12
|
+
class?: string;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
let {
|
|
16
|
+
href,
|
|
17
|
+
label,
|
|
18
|
+
description,
|
|
19
|
+
icon = '+',
|
|
20
|
+
badge,
|
|
21
|
+
position = 'bottom-right',
|
|
22
|
+
target,
|
|
23
|
+
ariaLabel,
|
|
24
|
+
class: className = '',
|
|
25
|
+
}: Props = $props();
|
|
26
|
+
</script>
|
|
27
|
+
|
|
28
|
+
<div class="lite-float-button {className}" data-position={position}>
|
|
29
|
+
{#if href}
|
|
30
|
+
<a class="lite-float-button__control" href={href} {target} aria-label={ariaLabel ?? label ?? description ?? 'Float button'}>
|
|
31
|
+
<span aria-hidden="true">{icon}</span>
|
|
32
|
+
{#if label || description}<span><strong>{label}</strong>{#if description}<small>{description}</small>{/if}</span>{/if}
|
|
33
|
+
{#if badge !== undefined}<span class="lite-badge lite-badge-danger">{badge}</span>{/if}
|
|
34
|
+
</a>
|
|
35
|
+
{:else}
|
|
36
|
+
<span class="lite-float-button__control" role="note" aria-label={ariaLabel ?? label ?? 'Float button'}>
|
|
37
|
+
<span aria-hidden="true">{icon}</span>
|
|
38
|
+
{#if label}<span><strong>{label}</strong>{#if description}<small>{description}</small>{/if}</span>{/if}
|
|
39
|
+
</span>
|
|
40
|
+
{/if}
|
|
41
|
+
</div>
|
|
42
|
+
|
|
43
|
+
<style>
|
|
44
|
+
.lite-float-button { position: fixed; z-index: 60; }
|
|
45
|
+
.lite-float-button[data-position='bottom-right'] { right: 24px; bottom: 24px; }
|
|
46
|
+
.lite-float-button[data-position='bottom-left'] { left: 24px; bottom: 24px; }
|
|
47
|
+
.lite-float-button[data-position='top-right'] { top: 24px; right: 24px; }
|
|
48
|
+
.lite-float-button[data-position='top-left'] { top: 24px; left: 24px; }
|
|
49
|
+
.lite-float-button__control { display: inline-flex; align-items: center; min-height: 40px; padding: 0 16px; border: 1px solid #E5E6EB; border-radius: 999px; background: #fff; color: #1D2129; box-shadow: 0 6px 20px rgba(29, 33, 41, 0.16); text-decoration: none; }
|
|
50
|
+
.lite-float-button__control:hover { color: #165DFF; text-decoration: none; }
|
|
51
|
+
.lite-float-button__control small { display: block; color: #86909C; font-size: 11px; }
|
|
52
|
+
|
|
53
|
+
.lite-float-button__control > * + * { margin-left: 8px; }
|
|
54
|
+
</style>
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
interface Props {
|
|
2
|
+
href?: string;
|
|
3
|
+
label?: string;
|
|
4
|
+
description?: string;
|
|
5
|
+
icon?: string;
|
|
6
|
+
badge?: string | number;
|
|
7
|
+
position?: 'bottom-right' | 'bottom-left' | 'top-right' | 'top-left';
|
|
8
|
+
target?: string;
|
|
9
|
+
ariaLabel?: string;
|
|
10
|
+
/** Caller class merged with the built-in class list. */
|
|
11
|
+
class?: string;
|
|
12
|
+
}
|
|
13
|
+
declare const LiteFloatButton: import("svelte").Component<Props, {}, "">;
|
|
14
|
+
type LiteFloatButton = ReturnType<typeof LiteFloatButton>;
|
|
15
|
+
export default LiteFloatButton;
|
|
@@ -99,7 +99,7 @@
|
|
|
99
99
|
<style>
|
|
100
100
|
.sv-lite-gantt-container {
|
|
101
101
|
display: block;
|
|
102
|
-
border: 1px solid #
|
|
102
|
+
border: 1px solid #E5E6EB;
|
|
103
103
|
border-radius: 6px;
|
|
104
104
|
padding: 12px;
|
|
105
105
|
background-color: #ffffff;
|
|
@@ -109,7 +109,7 @@
|
|
|
109
109
|
.sv-lite-gantt-title {
|
|
110
110
|
margin-bottom: 10px;
|
|
111
111
|
font-size: 13px;
|
|
112
|
-
color: #
|
|
112
|
+
color: #1D2129;
|
|
113
113
|
}
|
|
114
114
|
.sv-lite-gantt-table {
|
|
115
115
|
width: 100%;
|
|
@@ -117,7 +117,7 @@
|
|
|
117
117
|
text-align: center;
|
|
118
118
|
}
|
|
119
119
|
.sv-lite-gantt-table th, .sv-lite-gantt-table td {
|
|
120
|
-
border: 1px solid #
|
|
120
|
+
border: 1px solid #E5E6EB;
|
|
121
121
|
padding: 6px;
|
|
122
122
|
}
|
|
123
123
|
.sv-lite-th-task, .sv-lite-td-task {
|
|
@@ -128,50 +128,50 @@
|
|
|
128
128
|
.sv-lite-th-day {
|
|
129
129
|
min-width: 28px;
|
|
130
130
|
font-size: 10px;
|
|
131
|
-
background-color: #
|
|
132
|
-
color: #
|
|
131
|
+
background-color: #F7F8FA;
|
|
132
|
+
color: #4E5969;
|
|
133
133
|
}
|
|
134
134
|
.sv-lite-gantt-badge {
|
|
135
135
|
display: inline-block;
|
|
136
136
|
padding: 2px 6px;
|
|
137
137
|
border-radius: 3px;
|
|
138
138
|
font-size: 10px;
|
|
139
|
-
text-transform:
|
|
139
|
+
text-transform: none;
|
|
140
140
|
}
|
|
141
141
|
.sv-lite-completed {
|
|
142
|
-
background-color: #
|
|
143
|
-
color: #
|
|
142
|
+
background-color: #E8FFEA;
|
|
143
|
+
color: #009A29;
|
|
144
144
|
}
|
|
145
145
|
.sv-lite-delayed {
|
|
146
|
-
background-color: #
|
|
147
|
-
color: #
|
|
146
|
+
background-color: #FFECE8;
|
|
147
|
+
color: #CB272D;
|
|
148
148
|
}
|
|
149
149
|
.sv-lite-in_progress {
|
|
150
|
-
background-color: #
|
|
151
|
-
color: #
|
|
150
|
+
background-color: #E8F3FF;
|
|
151
|
+
color: #0E42D2;
|
|
152
152
|
}
|
|
153
153
|
.sv-lite-planned {
|
|
154
|
-
background-color: #
|
|
155
|
-
color: #
|
|
154
|
+
background-color: #F2F3F5;
|
|
155
|
+
color: #4E5969;
|
|
156
156
|
}
|
|
157
157
|
.sv-lite-cell-active {
|
|
158
|
-
background-color: #
|
|
158
|
+
background-color: #165DFF;
|
|
159
159
|
color: #ffffff;
|
|
160
160
|
}
|
|
161
161
|
.sv-lite-bg-completed {
|
|
162
|
-
background-color: #
|
|
162
|
+
background-color: #00B42A;
|
|
163
163
|
}
|
|
164
164
|
.sv-lite-bg-delayed {
|
|
165
|
-
background-color: #
|
|
165
|
+
background-color: #F53F3F;
|
|
166
166
|
}
|
|
167
167
|
.sv-lite-bg-in_progress {
|
|
168
|
-
background-color: #
|
|
168
|
+
background-color: #165DFF;
|
|
169
169
|
}
|
|
170
170
|
.sv-lite-bg-planned {
|
|
171
|
-
background-color: #
|
|
171
|
+
background-color: #86909C;
|
|
172
172
|
}
|
|
173
173
|
.sv-lite-cell-progress {
|
|
174
|
-
font-size:
|
|
174
|
+
font-size: 12px;
|
|
175
175
|
font-weight: bold;
|
|
176
176
|
}
|
|
177
177
|
</style>
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import type { Snippet } from 'svelte';
|
|
3
|
+
|
|
4
|
+
interface Props {
|
|
5
|
+
columns?: number;
|
|
6
|
+
gap?: 'sm' | 'md' | 'lg';
|
|
7
|
+
/** Caller class merged with the built-in class list. */
|
|
8
|
+
class?: string;
|
|
9
|
+
children: Snippet;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
let { columns = 3, gap = 'md', class: className = '', children }: Props = $props();
|
|
13
|
+
const safeColumns = $derived(columns >= 4 ? 4 : columns === 2 ? 2 : 3);
|
|
14
|
+
</script>
|
|
15
|
+
|
|
16
|
+
<div class="lite-grid {className}" data-columns={safeColumns} data-gap={gap}>
|
|
17
|
+
{@render children()}
|
|
18
|
+
</div>
|
|
19
|
+
|
|
20
|
+
<style>
|
|
21
|
+
.lite-grid { display: flex; flex-wrap: wrap; margin: -6px; }
|
|
22
|
+
.lite-grid > * { box-sizing: border-box; width: calc(33.333% - 12px); margin: 6px; }
|
|
23
|
+
.lite-grid[data-columns='2'] > * { width: calc(50% - 12px); }
|
|
24
|
+
.lite-grid[data-columns='4'] > * { width: calc(25% - 12px); }
|
|
25
|
+
.lite-grid[data-gap='sm'] { margin: -2px; }
|
|
26
|
+
.lite-grid[data-gap='sm'] > * { width: calc(33.333% - 4px); margin: 2px; }
|
|
27
|
+
.lite-grid[data-gap='sm'][data-columns='2'] > * { width: calc(50% - 4px); }
|
|
28
|
+
.lite-grid[data-gap='sm'][data-columns='4'] > * { width: calc(25% - 4px); }
|
|
29
|
+
.lite-grid[data-gap='lg'] { margin: -10px; }
|
|
30
|
+
.lite-grid[data-gap='lg'] > * { width: calc(33.333% - 20px); margin: 10px; }
|
|
31
|
+
.lite-grid[data-gap='lg'][data-columns='2'] > * { width: calc(50% - 20px); }
|
|
32
|
+
.lite-grid[data-gap='lg'][data-columns='4'] > * { width: calc(25% - 20px); }
|
|
33
|
+
@media (max-width: 720px) { .lite-grid > * { width: calc(100% - 12px) !important; } }
|
|
34
|
+
</style>
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { Snippet } from 'svelte';
|
|
2
|
+
interface Props {
|
|
3
|
+
columns?: number;
|
|
4
|
+
gap?: 'sm' | 'md' | 'lg';
|
|
5
|
+
/** Caller class merged with the built-in class list. */
|
|
6
|
+
class?: string;
|
|
7
|
+
children: Snippet;
|
|
8
|
+
}
|
|
9
|
+
declare const LiteGrid: import("svelte").Component<Props, {}, "">;
|
|
10
|
+
type LiteGrid = ReturnType<typeof LiteGrid>;
|
|
11
|
+
export default LiteGrid;
|