@steedos-widgets/sortable 6.3.11-beta.9 → 6.3.11
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/assets.json +5 -5
- package/dist/sortable.cjs.js +24 -5
- package/dist/sortable.cjs.js.map +1 -1
- package/dist/sortable.esm.js +24 -5
- package/dist/sortable.esm.js.map +1 -1
- package/dist/sortable.umd.js +24 -5
- package/package.json +3 -3
package/dist/assets.json
CHANGED
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
{
|
|
4
4
|
"package": "@steedos-widgets/sortable",
|
|
5
5
|
"urls": [
|
|
6
|
-
"https://unpkg.com/@steedos-widgets/sortable@6.3.11
|
|
7
|
-
"https://unpkg.com/@steedos-widgets/sortable@6.3.11
|
|
6
|
+
"https://unpkg.com/@steedos-widgets/sortable@6.3.11/dist/sortable.umd.js",
|
|
7
|
+
"https://unpkg.com/@steedos-widgets/sortable@6.3.11/dist/sortable.umd.css"
|
|
8
8
|
],
|
|
9
9
|
"library": "BuilderSortable"
|
|
10
10
|
}
|
|
@@ -15,10 +15,10 @@
|
|
|
15
15
|
"npm": {
|
|
16
16
|
"package": "@steedos-widgets/sortable"
|
|
17
17
|
},
|
|
18
|
-
"url": "https://unpkg.com/@steedos-widgets/sortable@6.3.11
|
|
18
|
+
"url": "https://unpkg.com/@steedos-widgets/sortable@6.3.11/dist/meta.js",
|
|
19
19
|
"urls": {
|
|
20
|
-
"default": "https://unpkg.com/@steedos-widgets/sortable@6.3.11
|
|
21
|
-
"design": "https://unpkg.com/@steedos-widgets/sortable@6.3.11
|
|
20
|
+
"default": "https://unpkg.com/@steedos-widgets/sortable@6.3.11/dist/meta.js",
|
|
21
|
+
"design": "https://unpkg.com/@steedos-widgets/sortable@6.3.11/dist/meta.js"
|
|
22
22
|
}
|
|
23
23
|
}
|
|
24
24
|
]
|
package/dist/sortable.cjs.js
CHANGED
|
@@ -53986,7 +53986,7 @@ const Router = {
|
|
|
53986
53986
|
* @Author: baozhoutao@steedos.com
|
|
53987
53987
|
* @Date: 2022-07-20 16:29:22
|
|
53988
53988
|
* @LastEditors: baozhoutao@steedos.com
|
|
53989
|
-
* @LastEditTime: 2024-
|
|
53989
|
+
* @LastEditTime: 2024-11-17 13:05:44
|
|
53990
53990
|
* @Description:
|
|
53991
53991
|
*/
|
|
53992
53992
|
|
|
@@ -54011,13 +54011,29 @@ if(typeof window != 'undefined'){
|
|
|
54011
54011
|
window.getImageFieldUrl = getImageFieldUrl;
|
|
54012
54012
|
}
|
|
54013
54013
|
|
|
54014
|
+
|
|
54015
|
+
|
|
54016
|
+
// js color
|
|
54017
|
+
|
|
54018
|
+
function toGrayscale(r, g, b){
|
|
54019
|
+
return (
|
|
54020
|
+
0.2126 * r +
|
|
54021
|
+
0.7152 * g +
|
|
54022
|
+
0.0722 * b
|
|
54023
|
+
);
|
|
54024
|
+
}
|
|
54025
|
+
|
|
54026
|
+
function isLight(r, g, b){
|
|
54027
|
+
// 专业的亮度是 > 255 / 2. 此处的阈值调整为200
|
|
54028
|
+
return toGrayscale(r, g, b) > 200
|
|
54029
|
+
}
|
|
54030
|
+
|
|
54014
54031
|
function getContrastColor(bgColor) {
|
|
54015
54032
|
var backgroundColor = (bgColor.charAt(0) === '#') ? bgColor.substring(1, 7) : bgColor;
|
|
54016
54033
|
var r = parseInt(backgroundColor.substr(0, 2), 16);
|
|
54017
54034
|
var g = parseInt(backgroundColor.substr(2, 2), 16);
|
|
54018
54035
|
var b = parseInt(backgroundColor.substr(4, 2), 16);
|
|
54019
|
-
|
|
54020
|
-
return brightness < 128 ? "#ffffff" : "#000000";
|
|
54036
|
+
return isLight(r, g, b) ? "#000000" : "#ffffff";
|
|
54021
54037
|
}
|
|
54022
54038
|
|
|
54023
54039
|
function getLookupListView(refObjectConfig) {
|
|
@@ -54126,7 +54142,7 @@ function getSelectMap(selectOptions){
|
|
|
54126
54142
|
if(optionColor && optionColor != "undefined"){
|
|
54127
54143
|
const background = optionColor.charAt(0) === '#' ? optionColor : '#'+optionColor;
|
|
54128
54144
|
const color = getContrastColor(background);
|
|
54129
|
-
const optionColorStyle = 'background:'+background+';color:'+color+';line-height:1.5rem';
|
|
54145
|
+
const optionColorStyle = 'background:'+background+';color:'+color+';line-height:1.5rem;font-size:14px';
|
|
54130
54146
|
map[optionValue] = `<span class="rounded-xl px-2 py-1" style='${optionColorStyle}'>${option.label}</span>`;
|
|
54131
54147
|
}else {
|
|
54132
54148
|
map[optionValue] = option.label;
|
|
@@ -54540,7 +54556,7 @@ async function getPage({type, pageId = '', appId, objectName = '', recordId = ''
|
|
|
54540
54556
|
* @Author: baozhoutao@steedos.com
|
|
54541
54557
|
* @Date: 2022-10-28 14:15:09
|
|
54542
54558
|
* @LastEditors: baozhoutao@steedos.com
|
|
54543
|
-
* @LastEditTime: 2024-
|
|
54559
|
+
* @LastEditTime: 2024-11-14 10:50:01
|
|
54544
54560
|
* @Description:
|
|
54545
54561
|
*/
|
|
54546
54562
|
|
|
@@ -54599,6 +54615,7 @@ async function getLookupLinkOnClick(field, options) {
|
|
|
54599
54615
|
"title": " ",
|
|
54600
54616
|
"headerClassName": "hidden",
|
|
54601
54617
|
"size": "lg",
|
|
54618
|
+
"width": "70%",
|
|
54602
54619
|
"bodyClassName": "p-0 m-0 bg-gray-100",
|
|
54603
54620
|
"closeOnEsc": true,
|
|
54604
54621
|
"closeOnOutside": true,
|
|
@@ -55691,6 +55708,7 @@ async function getColumnItemOnClick(field, options){
|
|
|
55691
55708
|
"title": " ",
|
|
55692
55709
|
"headerClassName": "hidden",
|
|
55693
55710
|
"size": "lg",
|
|
55711
|
+
"width": "70%",
|
|
55694
55712
|
"bodyClassName": "p-0 m-0 bg-gray-100",
|
|
55695
55713
|
"closeOnEsc": true,
|
|
55696
55714
|
"closeOnOutside": true,
|
|
@@ -60974,6 +60992,7 @@ async function convertSFieldToAmisField(field, readonly, ctx) {
|
|
|
60974
60992
|
type: "static-mapping",
|
|
60975
60993
|
name: field.name,
|
|
60976
60994
|
label: field.label,
|
|
60995
|
+
options: field.options,
|
|
60977
60996
|
map: map
|
|
60978
60997
|
};
|
|
60979
60998
|
}else {
|