@castlabs/ui 7.13.0 → 7.15.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/dist/castlabs-ui-editor.common.js +2 -2
- package/dist/castlabs-ui-editor.common.js.map +1 -1
- package/dist/castlabs-ui-editor.umd.js +2 -2
- package/dist/castlabs-ui-editor.umd.js.map +1 -1
- package/dist/castlabs-ui.common.js +3 -3
- package/dist/castlabs-ui.common.js.map +1 -1
- package/dist/castlabs-ui.core.js +52 -9
- package/dist/castlabs-ui.css +1 -1
- package/dist/castlabs-ui.module.d.ts +1 -0
- package/dist/castlabs-ui.module.js +52 -9
- package/dist/castlabs-ui.umd.js +4 -4
- package/dist/castlabs-ui.umd.js.map +1 -1
- package/package.json +14 -14
- package/src/components/ClList/style.variables.scss +10 -0
- package/src/components/navigation/ClNavSide/ClNavDrawer/style.scss +13 -0
- package/src/components/navigation/ClNavTop/style.scss +2 -1
- package/src/components/section/ClSectionDetails/style.scss +10 -0
- package/src/components/table/ClTableCel/Links/style.scss +5 -5
- package/src/components/table/ClTableCel/style.variables.scss +13 -0
- package/src/components/widget/ClCookieBanner/style.scss +1 -1
- package/src/components/widget/ClPage/style.scss +55 -0
- package/src/styles/abstracts/color.scss +3 -0
- package/src/styles/abstracts/responsive.scss +15 -3
- package/src/styles/abstracts/typography.scss +2 -3
- package/src/styles/assets/logo.scss +0 -6
- package/src/styles/layout/meta.scss +1 -1
- package/src/styles/layout/typography.scss +10 -1
- package/src/styles/ui.scss +1 -0
- package/types/castlabs-ui.module.d.ts +1 -0
- package/types/index.d.ts +43 -6
package/dist/castlabs-ui.core.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* @castlabs/ui v7.
|
|
1
|
+
/* @castlabs/ui v7.15.0 */
|
|
2
2
|
|
|
3
3
|
/*!
|
|
4
4
|
* Bootstrap v5.3.8 (https://getbootstrap.com/)
|
|
@@ -174,20 +174,20 @@ function clCookieBannerShow (accept = clCookieBannerAccept, decline = clCookieBa
|
|
|
174
174
|
>privacy policy</a>.
|
|
175
175
|
</p>
|
|
176
176
|
|
|
177
|
-
<div class="cl-spacing-box
|
|
177
|
+
<div class="cl-spacing-box cl-spread">
|
|
178
178
|
<button
|
|
179
|
-
id="cl-button-cookie-
|
|
179
|
+
id="cl-button-cookie-decline"
|
|
180
180
|
type="button"
|
|
181
|
-
class="btn btn-sm cl-color-
|
|
181
|
+
class="btn btn-sm cl-color-night it-cancel"
|
|
182
182
|
>
|
|
183
|
-
|
|
183
|
+
Decline
|
|
184
184
|
</button>
|
|
185
185
|
<button
|
|
186
|
-
id="cl-button-cookie-
|
|
186
|
+
id="cl-button-cookie-accept"
|
|
187
187
|
type="button"
|
|
188
|
-
class="btn btn-sm cl-color-
|
|
188
|
+
class="btn btn-sm cl-color-red it-ok"
|
|
189
189
|
>
|
|
190
|
-
|
|
190
|
+
Accept
|
|
191
191
|
</button>
|
|
192
192
|
</div>
|
|
193
193
|
</div>
|
|
@@ -621,7 +621,11 @@ const APPS = {
|
|
|
621
621
|
roles: [ROLE.VTK_USER_URN, ROLE.VTK_ADMIN_URN],
|
|
622
622
|
title: SERVICE.VTK,
|
|
623
623
|
urlManage: (env, oid) =>
|
|
624
|
-
getEnvUrl(
|
|
624
|
+
getEnvUrl(
|
|
625
|
+
env,
|
|
626
|
+
`https://vtk.castlabs.com/${oid}/jobs/`,
|
|
627
|
+
`https://vtks.castlabs.com/${oid}/jobs/`
|
|
628
|
+
),
|
|
625
629
|
urlPlan: (env, oid) => urlCS(env, oid, '/plans/vtk'),
|
|
626
630
|
sidenav: true
|
|
627
631
|
}
|
|
@@ -1187,6 +1191,45 @@ function clFormatDateTimeUTC (date, seconds = false) {
|
|
|
1187
1191
|
return `${clFormatDate(date)} ${clFormatTimeUTC(date, seconds)}`
|
|
1188
1192
|
}
|
|
1189
1193
|
|
|
1194
|
+
/**
|
|
1195
|
+
* Format a date and time into a sortable string.
|
|
1196
|
+
*
|
|
1197
|
+
* @param {Date} date Date to format.
|
|
1198
|
+
* @param {boolean} year If true (default), the output will contain a year.
|
|
1199
|
+
* @param {boolean} month If true (default), the output will contain a year.
|
|
1200
|
+
* @param {boolean} day If true (default), the output will contain a year.
|
|
1201
|
+
* @param {boolean} hour If true (default), the output will contain hour.
|
|
1202
|
+
* @param {boolean} minute If true (default), the output will contain hours and minutes.
|
|
1203
|
+
* @param {boolean} seconds If true (default false), the output will contain seconds.
|
|
1204
|
+
* @return {string} Formatted date, e.g. '2021-08-01 18:21'.
|
|
1205
|
+
*/
|
|
1206
|
+
function clFormatDateTimeTabularUTC (
|
|
1207
|
+
date,
|
|
1208
|
+
year = true,
|
|
1209
|
+
month = true,
|
|
1210
|
+
day = true,
|
|
1211
|
+
time = true,
|
|
1212
|
+
seconds = false
|
|
1213
|
+
) {
|
|
1214
|
+
const YYYY = new Intl.DateTimeFormat('en', { year: 'numeric' }).format(date)
|
|
1215
|
+
const MM = new Intl.DateTimeFormat('en', { month: '2-digit' }).format(date)
|
|
1216
|
+
const DD = new Intl.DateTimeFormat('en', { day: '2-digit' }).format(date)
|
|
1217
|
+
const [hh, mm, ss] = [
|
|
1218
|
+
('' + date.getUTCHours()).padStart(2, '0'),
|
|
1219
|
+
('' + date.getUTCMinutes()).padStart(2, '0'),
|
|
1220
|
+
('' + date.getUTCSeconds()).padStart(2, '0')
|
|
1221
|
+
]
|
|
1222
|
+
|
|
1223
|
+
let result = ''
|
|
1224
|
+
if (year) result += ` ${YYYY}`
|
|
1225
|
+
if (month) result += `-${MM}`
|
|
1226
|
+
if (day) result += `-${DD}`
|
|
1227
|
+
if (time) result += ` ${hh}:${mm}`
|
|
1228
|
+
if (seconds) result += `:${ss}`
|
|
1229
|
+
|
|
1230
|
+
return result.trim()
|
|
1231
|
+
}
|
|
1232
|
+
|
|
1190
1233
|
/**
|
|
1191
1234
|
* Format the duration between two dates. Format can adapt on scale of duraction (years/weeks, milliseconds, ...)
|
|
1192
1235
|
*
|