lumiglass 1.1.1 → 1.2.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 +12 -0
- package/css/glass-lg.css +2 -7
- package/js/glass-liquid-engine.js +622 -643
- package/js/glass-webgl.js +7 -0
- package/js/glass.js +1 -1
- package/package.json +7 -3
package/js/glass-webgl.js
CHANGED
|
@@ -74,6 +74,9 @@
|
|
|
74
74
|
var LG_CSS = [
|
|
75
75
|
'html.lg-on [data-glass-live]{background:transparent!important;backdrop-filter:none!important;',
|
|
76
76
|
'-webkit-backdrop-filter:none!important;border-color:transparent!important;box-shadow:none!important}',
|
|
77
|
+
/* live 玻璃的内层件(磁贴 face 等)自带向下投影,会叠在引擎玻璃上形成"偏心暗圈" */
|
|
78
|
+
'html.lg-on [data-glass-live] .face,html.lg-on [data-glass-live] .knob,html.lg-on [data-glass-live] .track,',
|
|
79
|
+
'html.lg-on [data-glass-live] .box{box-shadow:none!important}',
|
|
77
80
|
'html.lg-on .lg-control[data-glass-live]:active{scale:none}',
|
|
78
81
|
'html.lg-ready [data-glass-backdrop]{visibility:hidden}',
|
|
79
82
|
'html.lg-on body{background:transparent!important}'
|
|
@@ -391,6 +394,10 @@
|
|
|
391
394
|
[].forEach.call(root.querySelectorAll('.tile .face'), function (face) {
|
|
392
395
|
face.classList.add('lg-control');
|
|
393
396
|
});
|
|
397
|
+
/* 磁贴只要单圈:玻璃不外扩(grow 0),去掉内圆外那层光环 */
|
|
398
|
+
[].forEach.call(root.querySelectorAll('.tile[data-glass]'), function (el) {
|
|
399
|
+
el.setAttribute('data-grow', '0');
|
|
400
|
+
});
|
|
394
401
|
tagSwitches(root);
|
|
395
402
|
tagSteppers(root);
|
|
396
403
|
tagProgressRings(root);
|
package/js/glass.js
CHANGED
|
@@ -322,7 +322,7 @@
|
|
|
322
322
|
'<path d="M12 2.5v2M12 19.5v2M4.9 4.9l1.4 1.4M17.7 17.7l1.4 1.4M2.5 12h2M19.5 12h2M4.9 19.1l1.4-1.4M17.7 6.3l1.4-1.4"/></svg>';
|
|
323
323
|
var ICON_MOON =
|
|
324
324
|
'<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.8" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true">' +
|
|
325
|
-
'<path d="M20.6 13.1A8.1 8.1 0 1 1 10.9 3.4a6.4 6.4 0 0 0 9.7 9.7z"/></svg>';
|
|
325
|
+
'<path d="M20.6 13.1A8.1 8.1 0 1 1 10.9 3.4a6.4 6.4 0 0 0 9.7 9.7z" transform="translate(1.4 1)"/></svg>';
|
|
326
326
|
|
|
327
327
|
function applyTheme(theme) {
|
|
328
328
|
if (theme === 'light' || theme === 'dark') {
|
package/package.json
CHANGED
|
@@ -1,13 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "lumiglass",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.2.0",
|
|
4
4
|
"description": "Lumi Glass · iOS 液态玻璃(Liquid Glass)CSS 组件库。零依赖纯 CSS:磨砂 + SVG 折射 + 镜面高光三层配方,130+ 类名,明暗双主题,Vue / React 可直接使用。",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Zhao Xinfei",
|
|
7
|
-
"homepage": "https://github.com/
|
|
7
|
+
"homepage": "https://github.com/zxf123-dev/lumiglass#readme",
|
|
8
8
|
"repository": {
|
|
9
9
|
"type": "git",
|
|
10
|
-
"url": "git+https://github.com/
|
|
10
|
+
"url": "git+https://github.com/zxf123-dev/lumiglass.git",
|
|
11
|
+
"directory": "lumiglass"
|
|
11
12
|
},
|
|
12
13
|
"keywords": [
|
|
13
14
|
"glassmorphism",
|
|
@@ -41,5 +42,8 @@
|
|
|
41
42
|
],
|
|
42
43
|
"publishConfig": {
|
|
43
44
|
"access": "public"
|
|
45
|
+
},
|
|
46
|
+
"bugs": {
|
|
47
|
+
"url": "https://github.com/zxf123-dev/lumiglass/issues"
|
|
44
48
|
}
|
|
45
49
|
}
|