sunrize 2.1.21 → 2.3.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/package.json +7 -7
- package/src/Application/Application.js +42 -27
- package/src/Application/Dashboard.js +33 -0
- package/src/Application/Document.js +122 -67
- package/src/Application/Footer.js +8 -3
- package/src/Application/GetText.js +20 -2
- package/src/Application/Interface.js +1 -1
- package/src/Application/Tabs.js +384 -49
- package/src/Application/TopBar.js +32 -0
- package/src/Controls/AddPrototypePopover.js +2 -1
- package/src/Controls/AnimationPropertiesPopover.js +3 -4
- package/src/Controls/AudioPreviewPopover.js +2 -8
- package/src/Controls/EditNodePopover.js +4 -1
- package/src/Controls/EditUserDefinedFieldPopover.js +4 -1
- package/src/Controls/ExportNodePopover.js +3 -1
- package/src/Controls/ImportNodePopover.js +3 -1
- package/src/Controls/Tabs.js +28 -2
- package/src/Controls/TexturePreviewPopover.js +5 -5
- package/src/Controls/VideoPreviewPopover.js +5 -8
- package/src/Controls/VolumeSliderPopover.js +41 -0
- package/src/Editors/AnimationEditor.js +19 -5
- package/src/Editors/BrowserFrame.js +40 -26
- package/src/Editors/Console.js +4 -1
- package/src/Editors/NodeList.js +2 -2
- package/src/Editors/SceneProperties.js +7 -3
- package/src/Editors/ScriptEditor.js +2 -1
- package/src/Parser/AudioParser.js +2 -2
- package/src/Parser/VideoParser.js +2 -3
- package/src/Tools/Core/X3DNodeTool.js +3 -3
- package/src/Tools/Core/X3DPrototypeInstanceTool.js +2 -0
- package/src/Tools/Grids/AxonometricGridTool.js +1 -1
- package/src/Tools/Grids/X3DGridNodeTool.js +7 -13
- package/src/Tools/Grouping/X3DBoundedObjectTool.x3d +4 -2
- package/src/Tools/Grouping/X3DTransformNodeTool.x3d +4 -2
- package/src/Tools/Rendering/X3DGeometryNodeTool.x3d +4 -3
- package/src/Tools/Shaders/ToolShader.x3d +6 -6
- package/src/Undo/Editor.js +81 -79
- package/src/assets/html/application-template.html +95 -27
- package/src/assets/html/application.html +95 -27
- package/src/assets/html/window-template.html +2 -1
- package/src/assets/html/window.html +2 -1
- package/src/assets/images/seti/audio.svg +44 -0
- package/src/assets/images/seti/default.svg +36 -0
- package/src/assets/images/seti/html.svg +37 -0
- package/src/assets/images/seti/image.svg +37 -0
- package/src/assets/images/seti/json.svg +37 -0
- package/src/assets/images/seti/obj.svg +50 -0
- package/src/assets/images/seti/others.svg +50 -0
- package/src/assets/images/seti/ply.svg +50 -0
- package/src/assets/images/seti/sog.svg +57 -0
- package/src/assets/images/seti/spz.svg +57 -0
- package/src/assets/images/seti/stl.svg +50 -0
- package/src/assets/images/seti/svg.svg +41 -0
- package/src/assets/images/seti/video.svg +36 -0
- package/src/assets/images/seti/vrml.svg +34 -0
- package/src/assets/locale/dictionary.json +43 -0
- package/src/assets/themes/default.css +312 -216
- package/src/assets/themes/system-colors.css +11 -11
|
@@ -74,7 +74,7 @@ class X3DNodeTool extends X3DBaseTool
|
|
|
74
74
|
if (!this [tool])
|
|
75
75
|
continue;
|
|
76
76
|
|
|
77
|
-
if (this [tool]
|
|
77
|
+
if (Object .hasOwn (this [tool], "selected"))
|
|
78
78
|
this [tool] .selected = value;
|
|
79
79
|
}
|
|
80
80
|
}
|
|
@@ -122,7 +122,7 @@ class X3DNodeTool extends X3DBaseTool
|
|
|
122
122
|
|
|
123
123
|
this .#innerNodes .push (this [tool] .getValue () .getInnerNode ());
|
|
124
124
|
|
|
125
|
-
if (this [tool]
|
|
125
|
+
if (Object .hasOwn (this [tool], "selected"))
|
|
126
126
|
this [tool] .selected = this .#selected;
|
|
127
127
|
}
|
|
128
128
|
}
|
|
@@ -479,7 +479,7 @@ class X3DNodeTool extends X3DBaseTool
|
|
|
479
479
|
toolPointing = true;
|
|
480
480
|
nodePush = false;
|
|
481
481
|
|
|
482
|
-
isNodeTraversable (
|
|
482
|
+
isNodeTraversable ()
|
|
483
483
|
{
|
|
484
484
|
return true;
|
|
485
485
|
}
|
|
@@ -10,6 +10,7 @@ class X3DPrototypeInstanceTool extends X3DNodeTool
|
|
|
10
10
|
{
|
|
11
11
|
super (node);
|
|
12
12
|
|
|
13
|
+
node .getProtoNode () ._updateInstances .addInterest ("set_toolRootNodes", this);
|
|
13
14
|
node .getBody () .rootNodes .addInterest ("set_toolRootNodes", this);
|
|
14
15
|
|
|
15
16
|
this .set_toolRootNodes ();
|
|
@@ -33,6 +34,7 @@ class X3DPrototypeInstanceTool extends X3DNodeTool
|
|
|
33
34
|
{
|
|
34
35
|
try
|
|
35
36
|
{
|
|
37
|
+
this .node .getProtoNode () ._updateInstances .removeInterest ("set_toolRootNodes", this);
|
|
36
38
|
this .node .getBody () .rootNodes .removeInterest ("set_toolRootNodes", this);
|
|
37
39
|
|
|
38
40
|
this .node .getInnerNode () .removeTool ();
|
|
@@ -62,7 +62,7 @@ class X3DGridNodeTool extends X3DActiveLayerNodeTool
|
|
|
62
62
|
if (!this .toolLayerNode)
|
|
63
63
|
return;
|
|
64
64
|
|
|
65
|
-
const configNode = Editor .
|
|
65
|
+
const configNode = Editor .getLayerConfigNode (this .getBrowser ());
|
|
66
66
|
|
|
67
67
|
for (const field of this .tool .getValue () .getFields ())
|
|
68
68
|
{
|
|
@@ -91,15 +91,15 @@ class X3DGridNodeTool extends X3DActiveLayerNodeTool
|
|
|
91
91
|
|
|
92
92
|
if (field .equals (this .tool .getFieldDefinition (field .getName ()) .getValue ()))
|
|
93
93
|
{
|
|
94
|
-
const configNode = Editor .
|
|
94
|
+
const configNode = Editor .getLayerConfigNode (this .getBrowser ());
|
|
95
95
|
|
|
96
96
|
configNode ?.removeMetaData (path);
|
|
97
97
|
}
|
|
98
98
|
else
|
|
99
99
|
{
|
|
100
|
-
const configNode = Editor .
|
|
100
|
+
const configNode = Editor .getLayerConfigNode (this .getBrowser (), true);
|
|
101
101
|
|
|
102
|
-
configNode
|
|
102
|
+
configNode ?.setMetaData (path, field);
|
|
103
103
|
}
|
|
104
104
|
}
|
|
105
105
|
|
|
@@ -168,15 +168,9 @@ class X3DGridNodeTool extends X3DActiveLayerNodeTool
|
|
|
168
168
|
|
|
169
169
|
const absoluteMatrix = transformTool .getCurrentMatrix () .multRight (transformTool .getModelMatrix ());
|
|
170
170
|
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
var position = transformTool .getSubBBox (new X3D .Box3 ()) .multRight (absoluteMatrix) .center;
|
|
175
|
-
}
|
|
176
|
-
else
|
|
177
|
-
{
|
|
178
|
-
var position = absoluteMatrix .multVecMatrix (transformTool ._center .getValue () .copy ());
|
|
179
|
-
}
|
|
171
|
+
const position = transformTool .tool .keepCenter || !this .tool .snapToCenter
|
|
172
|
+
? transformTool .getSubBBox (new X3D .Box3 ()) .multRight (absoluteMatrix) .center
|
|
173
|
+
: absoluteMatrix .multVecMatrix (transformTool ._center .getValue () .copy ());
|
|
180
174
|
|
|
181
175
|
// Calculate snapping position and apply absolute translation.
|
|
182
176
|
|
|
@@ -53,7 +53,8 @@
|
|
|
53
53
|
<UnlitMaterial
|
|
54
54
|
transparency='1'/>
|
|
55
55
|
<DepthMode
|
|
56
|
-
polygonOffset='-1 -1'
|
|
56
|
+
polygonOffset='-1 -1'
|
|
57
|
+
depthRange='0 0.9999'/>
|
|
57
58
|
</Appearance>
|
|
58
59
|
<Box
|
|
59
60
|
size='1 1 1'/>
|
|
@@ -77,7 +78,8 @@
|
|
|
77
78
|
</IS>
|
|
78
79
|
</UnlitMaterial>
|
|
79
80
|
<DepthMode
|
|
80
|
-
polygonOffset='-1 -1'
|
|
81
|
+
polygonOffset='-1 -1'
|
|
82
|
+
depthRange='0 0.9999'/>
|
|
81
83
|
</Appearance>
|
|
82
84
|
<IndexedLineSet
|
|
83
85
|
coordIndex='0, 1, 2, 3, 0, -1, 4, 5, 6, 7, 4, -1, 0, 4, -1, 3, 7, -1, 1, 5, -1, 2, 6, -1'>
|
|
@@ -91,7 +91,8 @@
|
|
|
91
91
|
<UnlitMaterial
|
|
92
92
|
transparency='1'/>
|
|
93
93
|
<DepthMode
|
|
94
|
-
polygonOffset='-1 -1'
|
|
94
|
+
polygonOffset='-1 -1'
|
|
95
|
+
depthRange='0 0.9999'/>
|
|
95
96
|
</Appearance>
|
|
96
97
|
<Box
|
|
97
98
|
size='1 1 1'/>
|
|
@@ -111,7 +112,8 @@
|
|
|
111
112
|
</IS>
|
|
112
113
|
</UnlitMaterial>
|
|
113
114
|
<DepthMode
|
|
114
|
-
polygonOffset='-1 -1'
|
|
115
|
+
polygonOffset='-1 -1'
|
|
116
|
+
depthRange='0 0.9999'/>
|
|
115
117
|
</Appearance>
|
|
116
118
|
<IndexedLineSet
|
|
117
119
|
coordIndex='0, 1, 2, 3, 0, -1, 4, 5, 6, 7, 4, -1, 0, 4, -1, 3, 7, -1, 1, 5, -1, 2, 6, -1'>
|
|
@@ -8,8 +8,8 @@
|
|
|
8
8
|
<meta name='created' content='Tue, 28 Nov 2023 21:59:27 GMT'/>
|
|
9
9
|
<meta name='comment' content='Rise and Shine'/>
|
|
10
10
|
<meta name='creator' content='Holger Seelig'/>
|
|
11
|
-
<meta name='generator' content='Sunrize X3D Editor V2.0
|
|
12
|
-
<meta name='modified' content='Sun,
|
|
11
|
+
<meta name='generator' content='Sunrize X3D Editor V2.2.0, https://create3000.github.io/sunrize/'/>
|
|
12
|
+
<meta name='modified' content='Sun, 23 Aug 2026 08:15:22 GMT'/>
|
|
13
13
|
</head>
|
|
14
14
|
<Scene>
|
|
15
15
|
<ExternProtoDeclare name='ToolShader' url='"../Shaders/ToolShader.x3d"'>
|
|
@@ -62,7 +62,8 @@
|
|
|
62
62
|
</Material>
|
|
63
63
|
<ProtoInstance name='ToolShader' DEF='_1' containerField='shaders'/>
|
|
64
64
|
<DepthMode DEF='_2'
|
|
65
|
-
polygonOffset='-1 -1'
|
|
65
|
+
polygonOffset='-1 -1'
|
|
66
|
+
depthRange='0 0.9999'/>
|
|
66
67
|
</Appearance>
|
|
67
68
|
<IndexedLineSet>
|
|
68
69
|
<IS>
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
-
<!DOCTYPE X3D PUBLIC "ISO//Web3D//DTD X3D 4.
|
|
3
|
-
<X3D profile='Interchange' version='4.
|
|
2
|
+
<!DOCTYPE X3D PUBLIC "ISO//Web3D//DTD X3D 4.1//EN" "https://www.web3d.org/specifications/x3d-4.1.dtd">
|
|
3
|
+
<X3D profile='Interchange' version='4.1' xmlns:xsd='http://www.w3.org/2001/XMLSchema-instance' xsd:noNamespaceSchemaLocation='https://www.web3d.org/specifications/x3d-4.1.xsd'>
|
|
4
4
|
<head>
|
|
5
5
|
<component name='Shaders' level='1'/>
|
|
6
6
|
<meta name='comment' content='Rise and Shine'/>
|
|
7
7
|
<meta name='created' content='Sun, 03 Aug 2014 14:00:40 GMT'/>
|
|
8
8
|
<meta name='creator' content='Holger Seelig'/>
|
|
9
|
-
<meta name='generator' content='Sunrize X3D Editor
|
|
9
|
+
<meta name='generator' content='Sunrize X3D Editor V2.2.0, https://create3000.github.io/sunrize/'/>
|
|
10
10
|
<meta name='identifier' content='file:///Users/holger/Desktop/X_ITE/sunrize/src/sunrize/Tools/Shaders/ToolShader.x3d'/>
|
|
11
|
-
<meta name='modified' content='
|
|
11
|
+
<meta name='modified' content='Sun, 23 Aug 2026 08:14:24 GMT'/>
|
|
12
12
|
</head>
|
|
13
13
|
<Scene>
|
|
14
14
|
<ProtoDeclare name='ToolShader'>
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
<connect nodeField='instanced' protoField='instanced'/>
|
|
24
24
|
</IS>
|
|
25
25
|
<ShaderPart DEF='ToolVertexShader'>
|
|
26
|
-
<![CDATA[data:
|
|
26
|
+
<![CDATA[data:x-shader/x-fragment,#version 300 es
|
|
27
27
|
|
|
28
28
|
precision highp float;
|
|
29
29
|
|
|
@@ -58,7 +58,7 @@ main ()
|
|
|
58
58
|
</ShaderPart>
|
|
59
59
|
<ShaderPart DEF='ToolFragmentShader'
|
|
60
60
|
type='FRAGMENT'>
|
|
61
|
-
<![CDATA[data:
|
|
61
|
+
<![CDATA[data:x-shader/x-vertex,#version 300 es
|
|
62
62
|
|
|
63
63
|
precision highp float;
|
|
64
64
|
|
package/src/Undo/Editor.js
CHANGED
|
@@ -583,10 +583,8 @@ ${scene .toXMLString ({ html: true, indent: " " .repeat (6) }) .trimEnd () }
|
|
|
583
583
|
newURL .push (encodeURI (relativePath));
|
|
584
584
|
continue;
|
|
585
585
|
}
|
|
586
|
-
catch
|
|
587
|
-
{
|
|
588
|
-
// console .log (error)
|
|
589
|
-
}
|
|
586
|
+
catch
|
|
587
|
+
{ }
|
|
590
588
|
|
|
591
589
|
newURL .push (fileURL);
|
|
592
590
|
}
|
|
@@ -1915,12 +1913,14 @@ ${scene .toXMLString ({ html: true, indent: " " .repeat (6) }) .trimEnd () }
|
|
|
1915
1913
|
*
|
|
1916
1914
|
* @param {X3DBrowser} browser
|
|
1917
1915
|
* @param {UndoManager} undoManager
|
|
1916
|
+
* @returns X3DNode | null
|
|
1918
1917
|
*/
|
|
1919
|
-
static
|
|
1918
|
+
static getLayerConfigNode (browser, create = false, undoManager = UndoManager .shared)
|
|
1920
1919
|
{
|
|
1921
|
-
|
|
1922
|
-
|
|
1923
|
-
|
|
1920
|
+
if (browser .getActiveLayer () === browser .getWorld () .getLayerSet () .getLayer0 ())
|
|
1921
|
+
return this .getConfigNode (browser .currentScene, create, undoManager);
|
|
1922
|
+
|
|
1923
|
+
return browser .getActiveLayer ();
|
|
1924
1924
|
}
|
|
1925
1925
|
|
|
1926
1926
|
/**
|
|
@@ -1928,7 +1928,7 @@ ${scene .toXMLString ({ html: true, indent: " " .repeat (6) }) .trimEnd () }
|
|
|
1928
1928
|
* @param {X3DExecutionContext} executionContext
|
|
1929
1929
|
* @param {UndoManager} undoManager
|
|
1930
1930
|
*/
|
|
1931
|
-
static
|
|
1931
|
+
static getConfigNode (executionContext, create = false, undoManager = UndoManager .shared)
|
|
1932
1932
|
{
|
|
1933
1933
|
if (executionContext .getWorldInfos () .length)
|
|
1934
1934
|
return executionContext .getWorldInfos () .at (-1) .getValue ();
|
|
@@ -1939,6 +1939,72 @@ ${scene .toXMLString ({ html: true, indent: " " .repeat (6) }) .trimEnd () }
|
|
|
1939
1939
|
return null;
|
|
1940
1940
|
}
|
|
1941
1941
|
|
|
1942
|
+
/**
|
|
1943
|
+
*
|
|
1944
|
+
* @param {X3DExecutionContext} executionContext
|
|
1945
|
+
* @param {X3DNode} node
|
|
1946
|
+
* @param {string} path
|
|
1947
|
+
* @param {X3DField} value
|
|
1948
|
+
* @param {UndoManager} undoManager
|
|
1949
|
+
*/
|
|
1950
|
+
static setNodeMetaData (node, path, value, undoManager = UndoManager .shared)
|
|
1951
|
+
{
|
|
1952
|
+
node = node .valueOf ();
|
|
1953
|
+
|
|
1954
|
+
const
|
|
1955
|
+
hasValue = node .hasMetaData (path),
|
|
1956
|
+
oldValue = node .getMetaData (path, value .create ());
|
|
1957
|
+
|
|
1958
|
+
undoManager .beginUndo (_("Change Metadata of Node %s"), node .getTypeName ());
|
|
1959
|
+
|
|
1960
|
+
node .setMetaData (path, value);
|
|
1961
|
+
|
|
1962
|
+
undoManager .registerUndo (() =>
|
|
1963
|
+
{
|
|
1964
|
+
if (hasValue)
|
|
1965
|
+
this .setNodeMetaData (node, path, oldValue, undoManager);
|
|
1966
|
+
else
|
|
1967
|
+
this .removeNodeMetaData (node, path, oldValue, undoManager);
|
|
1968
|
+
});
|
|
1969
|
+
|
|
1970
|
+
this .requestUpdateInstances (node, undoManager);
|
|
1971
|
+
|
|
1972
|
+
undoManager .endUndo ();
|
|
1973
|
+
}
|
|
1974
|
+
|
|
1975
|
+
/**
|
|
1976
|
+
*
|
|
1977
|
+
* @param {X3DExecutionContext} executionContext
|
|
1978
|
+
* @param {X3DNode} node
|
|
1979
|
+
* @param {string} path
|
|
1980
|
+
* @param {X3DField} type
|
|
1981
|
+
* @param {UndoManager} undoManager
|
|
1982
|
+
*/
|
|
1983
|
+
static removeNodeMetaData (node, path, type, undoManager = UndoManager .shared)
|
|
1984
|
+
{
|
|
1985
|
+
node = node .valueOf ();
|
|
1986
|
+
|
|
1987
|
+
const hasValue = node .hasMetaData (path);
|
|
1988
|
+
|
|
1989
|
+
if (!hasValue)
|
|
1990
|
+
return;
|
|
1991
|
+
|
|
1992
|
+
const oldValue = node .getMetaData (path, type .create ());
|
|
1993
|
+
|
|
1994
|
+
undoManager .beginUndo (_("Change Metadata of Node %s"), node .getTypeName ());
|
|
1995
|
+
|
|
1996
|
+
node .removeMetaData (path);
|
|
1997
|
+
|
|
1998
|
+
undoManager .registerUndo (() =>
|
|
1999
|
+
{
|
|
2000
|
+
this .setNodeMetaData (node, path, oldValue, undoManager);
|
|
2001
|
+
});
|
|
2002
|
+
|
|
2003
|
+
this .requestUpdateInstances (node, undoManager);
|
|
2004
|
+
|
|
2005
|
+
undoManager .endUndo ();
|
|
2006
|
+
}
|
|
2007
|
+
|
|
1942
2008
|
/**
|
|
1943
2009
|
*
|
|
1944
2010
|
* @param {X3DExecutionContext} executionContext
|
|
@@ -2202,8 +2268,6 @@ ${scene .toXMLString ({ html: true, indent: " " .repeat (6) }) .trimEnd () }
|
|
|
2202
2268
|
}
|
|
2203
2269
|
}
|
|
2204
2270
|
}
|
|
2205
|
-
|
|
2206
|
-
this .updateInstances (proto, undoManager);
|
|
2207
2271
|
}
|
|
2208
2272
|
else // Script node
|
|
2209
2273
|
{
|
|
@@ -2245,6 +2309,9 @@ ${scene .toXMLString ({ html: true, indent: " " .repeat (6) }) .trimEnd () }
|
|
|
2245
2309
|
}
|
|
2246
2310
|
}
|
|
2247
2311
|
|
|
2312
|
+
if (node instanceof X3D .X3DProtoDeclaration)
|
|
2313
|
+
this .updateInstances (node, undoManager);
|
|
2314
|
+
|
|
2248
2315
|
undoManager .registerUndo (() =>
|
|
2249
2316
|
{
|
|
2250
2317
|
this .#changeAccessType (executionContext, node, field, oldAccessType, undoManager);
|
|
@@ -2363,8 +2430,6 @@ ${scene .toXMLString ({ html: true, indent: " " .repeat (6) }) .trimEnd () }
|
|
|
2363
2430
|
}
|
|
2364
2431
|
}
|
|
2365
2432
|
}
|
|
2366
|
-
|
|
2367
|
-
this .updateInstances (proto, undoManager);
|
|
2368
2433
|
}
|
|
2369
2434
|
else
|
|
2370
2435
|
{
|
|
@@ -2408,6 +2473,9 @@ ${scene .toXMLString ({ html: true, indent: " " .repeat (6) }) .trimEnd () }
|
|
|
2408
2473
|
for (const field of fields)
|
|
2409
2474
|
node .addUserDefinedField (field .getAccessType (), field .getName (), field);
|
|
2410
2475
|
|
|
2476
|
+
if (node instanceof X3D .X3DProtoDeclaration)
|
|
2477
|
+
this .updateInstances (node, undoManager);
|
|
2478
|
+
|
|
2411
2479
|
//
|
|
2412
2480
|
|
|
2413
2481
|
undoManager .registerUndo (() =>
|
|
@@ -2956,72 +3024,6 @@ ${scene .toXMLString ({ html: true, indent: " " .repeat (6) }) .trimEnd () }
|
|
|
2956
3024
|
return modelMatrices;
|
|
2957
3025
|
}
|
|
2958
3026
|
|
|
2959
|
-
/**
|
|
2960
|
-
*
|
|
2961
|
-
* @param {X3DExecutionContext} executionContext
|
|
2962
|
-
* @param {X3DNode} node
|
|
2963
|
-
* @param {string} path
|
|
2964
|
-
* @param {X3DField} value
|
|
2965
|
-
* @param {UndoManager} undoManager
|
|
2966
|
-
*/
|
|
2967
|
-
static setNodeMetaData (node, path, value, undoManager = UndoManager .shared)
|
|
2968
|
-
{
|
|
2969
|
-
node = node .valueOf ();
|
|
2970
|
-
|
|
2971
|
-
const
|
|
2972
|
-
hasValue = node .hasMetaData (path),
|
|
2973
|
-
oldValue = node .getMetaData (path, value .create ());
|
|
2974
|
-
|
|
2975
|
-
undoManager .beginUndo (_("Change Metadata of Node %s"), node .getTypeName ());
|
|
2976
|
-
|
|
2977
|
-
node .setMetaData (path, value);
|
|
2978
|
-
|
|
2979
|
-
undoManager .registerUndo (() =>
|
|
2980
|
-
{
|
|
2981
|
-
if (hasValue)
|
|
2982
|
-
this .setNodeMetaData (node, path, oldValue, undoManager);
|
|
2983
|
-
else
|
|
2984
|
-
this .removeNodeMetaData (node, path, oldValue, undoManager);
|
|
2985
|
-
});
|
|
2986
|
-
|
|
2987
|
-
this .requestUpdateInstances (node, undoManager);
|
|
2988
|
-
|
|
2989
|
-
undoManager .endUndo ();
|
|
2990
|
-
}
|
|
2991
|
-
|
|
2992
|
-
/**
|
|
2993
|
-
*
|
|
2994
|
-
* @param {X3DExecutionContext} executionContext
|
|
2995
|
-
* @param {X3DNode} node
|
|
2996
|
-
* @param {string} path
|
|
2997
|
-
* @param {X3DField} type
|
|
2998
|
-
* @param {UndoManager} undoManager
|
|
2999
|
-
*/
|
|
3000
|
-
static removeNodeMetaData (node, path, type, undoManager = UndoManager .shared)
|
|
3001
|
-
{
|
|
3002
|
-
node = node .valueOf ();
|
|
3003
|
-
|
|
3004
|
-
const hasValue = node .hasMetaData (path);
|
|
3005
|
-
|
|
3006
|
-
if (!hasValue)
|
|
3007
|
-
return;
|
|
3008
|
-
|
|
3009
|
-
const oldValue = node .getMetaData (path, type .create ());
|
|
3010
|
-
|
|
3011
|
-
undoManager .beginUndo (_("Change Metadata of Node %s"), node .getTypeName ());
|
|
3012
|
-
|
|
3013
|
-
node .removeMetaData (path);
|
|
3014
|
-
|
|
3015
|
-
undoManager .registerUndo (() =>
|
|
3016
|
-
{
|
|
3017
|
-
this .setNodeMetaData (node, path, oldValue, undoManager);
|
|
3018
|
-
});
|
|
3019
|
-
|
|
3020
|
-
this .requestUpdateInstances (node, undoManager);
|
|
3021
|
-
|
|
3022
|
-
undoManager .endUndo ();
|
|
3023
|
-
}
|
|
3024
|
-
|
|
3025
3027
|
/**
|
|
3026
3028
|
*
|
|
3027
3029
|
* @param {X3DExecutionContext} executionContext
|
|
@@ -7,9 +7,15 @@
|
|
|
7
7
|
<body>
|
|
8
8
|
<tab-group sortable="true">
|
|
9
9
|
<style>
|
|
10
|
+
@import url(../themes/media.css);
|
|
11
|
+
|
|
12
|
+
.material-symbols-outlined {
|
|
13
|
+
font-variation-settings: 'FILL' 0, 'wght' 300, 'GRAD' 0, 'opsz' 24;
|
|
14
|
+
}
|
|
15
|
+
|
|
10
16
|
::-webkit-scrollbar {
|
|
11
17
|
width: 8px;
|
|
12
|
-
height:
|
|
18
|
+
height: 4px;
|
|
13
19
|
}
|
|
14
20
|
|
|
15
21
|
::-webkit-scrollbar-track, /* Track */
|
|
@@ -21,6 +27,15 @@
|
|
|
21
27
|
/* Handle */
|
|
22
28
|
::-webkit-scrollbar-thumb {
|
|
23
29
|
background-color: var(--scrollbar-thumb-color);
|
|
30
|
+
border-radius: 2px;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
:hover::-webkit-scrollbar-thumb {
|
|
34
|
+
background-color: var(--scrollbar-thumb-color-hover);
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
.etabs .buttons {
|
|
38
|
+
display: none;
|
|
24
39
|
}
|
|
25
40
|
|
|
26
41
|
.etabs .nav {
|
|
@@ -33,60 +48,113 @@
|
|
|
33
48
|
white-space: nowrap;
|
|
34
49
|
}
|
|
35
50
|
|
|
51
|
+
.etabs .tab:not(.active, :hover, :focus, :first-child)::before {
|
|
52
|
+
content: "•";
|
|
53
|
+
position: absolute;
|
|
54
|
+
top: 9px;
|
|
55
|
+
left: -3px;
|
|
56
|
+
color: var(--text-disabled);
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
.etabs .tab:is(.active, :hover, :focus) + .tab::before {
|
|
60
|
+
display: none;
|
|
61
|
+
}
|
|
62
|
+
|
|
36
63
|
.etabs .tab {
|
|
37
|
-
background:
|
|
38
|
-
border
|
|
39
|
-
|
|
64
|
+
background: none;
|
|
65
|
+
border: 1px solid transparent !important;
|
|
66
|
+
border-radius: var(--window-tabs-height);
|
|
67
|
+
padding: 4px 6px 4px 9px !important;
|
|
40
68
|
color: var(--window-tabs-text-color);
|
|
41
69
|
font-family: var(--sans-serif);
|
|
42
70
|
box-shadow: none;
|
|
71
|
+
transition: background-color 200ms, border-color 200ms, color 200ms;
|
|
43
72
|
}
|
|
44
73
|
|
|
45
|
-
.etabs .tab:
|
|
46
|
-
|
|
74
|
+
.etabs .tab:hover,
|
|
75
|
+
.etabs .tab.active {
|
|
76
|
+
background-color: var(--window-tabs-background-color);
|
|
77
|
+
border-color: var(--border-color) !important;
|
|
47
78
|
}
|
|
48
79
|
|
|
49
80
|
.etabs .tab.active {
|
|
50
|
-
z-index: 1100;
|
|
51
|
-
background: var(--background-color);
|
|
52
81
|
color: var(--window-tabs-highlight-color);
|
|
53
82
|
}
|
|
54
83
|
|
|
55
|
-
.etabs
|
|
56
|
-
|
|
57
|
-
content: "";
|
|
58
|
-
position: relative;
|
|
59
|
-
display: block;
|
|
60
|
-
height: 1px;
|
|
61
|
-
width: 100%;
|
|
62
|
-
box-shadow: var(--tabs-shadow);
|
|
84
|
+
.etabs .tab:focus {
|
|
85
|
+
border-color: var(--system-blue) !important;
|
|
63
86
|
}
|
|
64
87
|
|
|
65
|
-
.etabs .
|
|
66
|
-
|
|
88
|
+
.etabs .tab-icon {
|
|
89
|
+
width: 16px;
|
|
90
|
+
height: 16px;
|
|
91
|
+
transform: scale(1.4);
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
.etabs .tab-icon img {
|
|
95
|
+
width: 16px;
|
|
96
|
+
height: 16px;
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
.etabs .tab-title {
|
|
100
|
+
margin-left: 5px;
|
|
67
101
|
}
|
|
68
102
|
|
|
69
|
-
.etabs .
|
|
70
|
-
.etabs .tab-
|
|
103
|
+
.etabs .tab-mute,
|
|
104
|
+
.etabs .tab-pin,
|
|
105
|
+
.etabs .tab-close,
|
|
106
|
+
.etabs .tab-close button {
|
|
107
|
+
appearance: none;
|
|
108
|
+
position: relative;
|
|
109
|
+
border: none;
|
|
110
|
+
border-radius: 4px;
|
|
71
111
|
background: none;
|
|
112
|
+
color: var(--window-tabs-text-color);
|
|
113
|
+
font-size: 18px;
|
|
114
|
+
top: 0px;
|
|
72
115
|
}
|
|
73
116
|
|
|
74
|
-
|
|
117
|
+
@media (prefers-color-scheme: light) {
|
|
118
|
+
.etabs .tab-mute:hover,
|
|
119
|
+
.etabs .tab-close:hover,
|
|
120
|
+
.etabs .tab-close:hover button {
|
|
121
|
+
background-color: var(--system-gray4);
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
.etabs .tab-mute:hover,
|
|
126
|
+
.etabs .tab-close:hover,
|
|
75
127
|
.etabs .tab-close:hover button {
|
|
76
128
|
color: var(--system-gray0);
|
|
77
129
|
}
|
|
78
130
|
|
|
79
|
-
.etabs .tab-
|
|
80
|
-
|
|
131
|
+
.etabs .tab-pin,
|
|
132
|
+
.etabs .tab-mute {
|
|
133
|
+
display: none;
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
.etabs .tab:not(.active) .tab-mute {
|
|
137
|
+
display: none !important;
|
|
81
138
|
}
|
|
82
139
|
|
|
83
|
-
.etabs .tab.active .tab-close button,
|
|
84
|
-
|
|
85
|
-
visibility: visible;
|
|
140
|
+
.etabs .tab:not(.active, :hover, :focus) :where(.tab-close button, .tab-mute, .tab-pin) {
|
|
141
|
+
color: var(--text-disabled);
|
|
86
142
|
}
|
|
87
143
|
|
|
144
|
+
.etabs .tab-mute {
|
|
145
|
+
margin-right: -3px;
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
.etabs .tab-mute,
|
|
149
|
+
.etabs .tab-pin,
|
|
88
150
|
.etabs .tab-close {
|
|
89
|
-
margin-left:
|
|
151
|
+
margin-left: 5px;
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
.etabs .tab-pin span {
|
|
155
|
+
margin-right: 2px;
|
|
156
|
+
font-size: inherit;
|
|
157
|
+
transform: rotate(45deg);
|
|
90
158
|
}
|
|
91
159
|
</style>
|
|
92
160
|
</tab-group>
|