lexgui 0.6.9 → 0.6.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/README.md +3 -3
- package/build/components/docmaker.js +2 -2
- package/build/components/timeline.js +102 -73
- package/build/lexgui-docs.css +0 -2
- package/build/lexgui.css +39 -4
- package/build/lexgui.js +640 -259
- package/build/lexgui.min.css +1 -1
- package/build/lexgui.min.js +1 -1
- package/build/lexgui.module.js +682 -301
- package/build/lexgui.module.min.js +1 -1
- package/changelog.md +33 -1
- package/demo.js +27 -0
- package/examples/editor.html +11 -6
- package/package.json +3 -2
package/README.md
CHANGED
|
@@ -6,15 +6,15 @@ NPM Package: [npmjs.com/package/lexgui](https://www.npmjs.com/package/lexgui)
|
|
|
6
6
|
|
|
7
7
|
<table>
|
|
8
8
|
<tr>
|
|
9
|
-
<td valign="top"><img src="data/
|
|
10
|
-
<td valign="top"><img src="data/
|
|
9
|
+
<td valign="top"><img src="data/Screenshot_Editor.png"/></td>
|
|
10
|
+
<td valign="top"><img src="data/Screenshot_Examples.png"/></td>
|
|
11
11
|
</tr>
|
|
12
12
|
</table>
|
|
13
13
|
|
|
14
14
|
<table>
|
|
15
15
|
<tr>
|
|
16
16
|
<td valign="top"><h3>Code Editor</h3><img src="data/Screenshot_Code.png"/></td>
|
|
17
|
-
<td valign="top"><h3>Node Graph Editor
|
|
17
|
+
<td valign="top"><h3>Node Graph Editor</h3><img src="data/Screenshot_Graph.png"/></td>
|
|
18
18
|
</tr>
|
|
19
19
|
</table>
|
|
20
20
|
|
|
@@ -7,9 +7,9 @@ if( !LX )
|
|
|
7
7
|
throw( "lexgui.js missing!" );
|
|
8
8
|
}
|
|
9
9
|
|
|
10
|
-
const CPP_KEY_WORDS = ['int', 'float', 'double', 'bool', 'char', 'wchar_t', 'const', 'static_cast', 'dynamic_cast', 'new', 'delete', 'void', 'true', 'false', 'auto', 'struct', 'typedef', 'nullptr', 'NULL', 'unsigned', 'namespace'];
|
|
10
|
+
const CPP_KEY_WORDS = ['int', 'float', 'double', 'bool', 'char', 'wchar_t', 'const', 'static_cast', 'dynamic_cast', 'new', 'delete', 'void', 'true', 'false', 'auto', 'struct', 'typedef', 'nullptr', 'NULL', 'unsigned', 'namespace', 'auto'];
|
|
11
11
|
const CLASS_WORDS = ['uint32_t', 'uint64_t', 'uint8_t'];
|
|
12
|
-
const STATEMENT_WORDS = ['for', 'if', 'else', 'return', 'continue', 'break', 'case', 'switch', 'while', 'import', 'from'];
|
|
12
|
+
const STATEMENT_WORDS = ['for', 'if', 'else', 'return', 'continue', 'break', 'case', 'switch', 'while', 'import', 'from', 'await'];
|
|
13
13
|
|
|
14
14
|
const JS_KEY_WORDS = ['var', 'let', 'const', 'static', 'function', 'null', 'undefined', 'new', 'delete', 'true', 'false', 'NaN', 'this'];
|
|
15
15
|
const HTML_ATTRIBUTES = ['html', 'charset', 'rel', 'src', 'href', 'crossorigin', 'type', 'lang'];
|
|
@@ -162,7 +162,7 @@ class Timeline {
|
|
|
162
162
|
const playbtn = header.addButton("playBtn", '', (value, event) => {
|
|
163
163
|
this.changeState();
|
|
164
164
|
}, { buttonClass: "accept", title: "Play", hideName: true, icon: "Play@solid", swap: "Pause@solid" });
|
|
165
|
-
playbtn.
|
|
165
|
+
playbtn.setState(this.playing, true);
|
|
166
166
|
|
|
167
167
|
header.addButton("stopBtn", '', (value, event) => {
|
|
168
168
|
this.setState(false, true); // skip callback of set state
|
|
@@ -972,7 +972,7 @@ class Timeline {
|
|
|
972
972
|
setState(state, skipCallback = false) {
|
|
973
973
|
this.playing = state;
|
|
974
974
|
|
|
975
|
-
this.header.widgets.playBtn.
|
|
975
|
+
this.header.widgets.playBtn.setState(this.playing, true);
|
|
976
976
|
|
|
977
977
|
if(this.onStateChange && !skipCallback) {
|
|
978
978
|
this.onStateChange(this.playing);
|
|
@@ -1290,7 +1290,7 @@ class Timeline {
|
|
|
1290
1290
|
* @param {obj} options set some values for the track instance (groups and trackIdx not included)
|
|
1291
1291
|
* @returns
|
|
1292
1292
|
*/
|
|
1293
|
-
instantiateTrack(options = {}) {
|
|
1293
|
+
instantiateTrack(options = {}, clone = false) {
|
|
1294
1294
|
return {
|
|
1295
1295
|
isTrack: true,
|
|
1296
1296
|
id: options.id ?? ( Math.floor(performance.now().toString()) + "_" + Math.floor(Math.random() * 0xffff) ), //must be unique, at least inside a group
|
|
@@ -1307,13 +1307,12 @@ class Timeline {
|
|
|
1307
1307
|
* @param {obj} animation data with which to generate an animationClip
|
|
1308
1308
|
* @returns
|
|
1309
1309
|
*/
|
|
1310
|
-
instantiateAnimationClip(options) {
|
|
1310
|
+
instantiateAnimationClip(options, clone = false) {
|
|
1311
1311
|
options = options ?? {};
|
|
1312
1312
|
const animationClip = {
|
|
1313
1313
|
id: options.id ?? (options.name ?? "animationClip"),
|
|
1314
1314
|
duration: options.duration ?? 0,
|
|
1315
1315
|
tracks: [],
|
|
1316
|
-
tracksPerGroup: options.tracksPerGroup ?? {},
|
|
1317
1316
|
data: options.data ?? null, // user defined data
|
|
1318
1317
|
};
|
|
1319
1318
|
return animationClip;
|
|
@@ -1433,42 +1432,42 @@ class KeyFramesTimeline extends Timeline {
|
|
|
1433
1432
|
* id, dim, values, times, selected, edited, hovered
|
|
1434
1433
|
* @returns
|
|
1435
1434
|
*/
|
|
1436
|
-
instantiateTrack(options ={}){
|
|
1435
|
+
instantiateTrack(options ={}, clone = false){
|
|
1437
1436
|
const track = super.instantiateTrack(options);
|
|
1438
1437
|
track.dim = Math.max(1,options.dim ?? 1); // >= 1
|
|
1439
1438
|
track.groupId = null,
|
|
1440
1439
|
track.groupTrackIdx = -1, // track Idx inside group only if in group
|
|
1441
1440
|
|
|
1442
|
-
track.values = new Float32Array(0);
|
|
1441
|
+
track.values = new Float32Array(0);
|
|
1443
1442
|
track.times = new Float32Array(0);
|
|
1444
1443
|
track.selected = [];
|
|
1445
1444
|
track.edited = [];
|
|
1446
1445
|
track.hovered = [];
|
|
1447
1446
|
|
|
1448
1447
|
if ( options.values && options.times ){
|
|
1449
|
-
track.values = options.values;
|
|
1450
|
-
track.times = options.times;
|
|
1448
|
+
track.values = clone ? options.values.slice() : options.values;
|
|
1449
|
+
track.times = clone ? options.times.slice() : options.times;
|
|
1451
1450
|
|
|
1452
1451
|
const numFrames = track.times.length;
|
|
1453
1452
|
if ( options.selected && options.selected.length == numFrames ){
|
|
1454
|
-
track.selected = options.selected;
|
|
1453
|
+
track.selected = clone ? options.selected.slice() : options.selected;
|
|
1455
1454
|
}else{
|
|
1456
1455
|
track.selected = (new Array(numFrames)).fill(false);
|
|
1457
1456
|
}
|
|
1458
1457
|
if ( options.edited && options.edited.length == numFrames ){
|
|
1459
|
-
track.edited = options.edited;
|
|
1458
|
+
track.edited = clone ? options.edited.slice() : options.edited;
|
|
1460
1459
|
}else{
|
|
1461
1460
|
track.edited = (new Array(numFrames)).fill(false);
|
|
1462
1461
|
}
|
|
1463
1462
|
if ( options.hovered && options.hovered.length == numFrames ){
|
|
1464
|
-
track.hovered = options.hovered;
|
|
1463
|
+
track.hovered = clone ? options.hovered.slice() : options.hovered;
|
|
1465
1464
|
}else{
|
|
1466
1465
|
track.hovered = (new Array(numFrames)).fill(false);
|
|
1467
1466
|
}
|
|
1468
1467
|
}
|
|
1469
1468
|
|
|
1470
1469
|
track.curves = options.curves ?? this.defaultCurves; // only works if dim == 1
|
|
1471
|
-
track.curvesRange = options.curvesRange ?? this.defaultCurvesRange.slice(
|
|
1470
|
+
track.curvesRange = ( options.curvesRange ?? this.defaultCurvesRange ).slice();
|
|
1472
1471
|
return track;
|
|
1473
1472
|
}
|
|
1474
1473
|
|
|
@@ -1477,9 +1476,11 @@ class KeyFramesTimeline extends Timeline {
|
|
|
1477
1476
|
* @param {obj} animation data with which to generate an animationClip
|
|
1478
1477
|
* @returns
|
|
1479
1478
|
*/
|
|
1480
|
-
instantiateAnimationClip(animation) {
|
|
1479
|
+
instantiateAnimationClip(animation, clone = false) {
|
|
1481
1480
|
|
|
1482
|
-
const animationClip = super.instantiateAnimationClip(animation);
|
|
1481
|
+
const animationClip = super.instantiateAnimationClip(animation, clone);
|
|
1482
|
+
|
|
1483
|
+
animationClip.tracksPerGroup = {};
|
|
1483
1484
|
|
|
1484
1485
|
if (animation && animation.tracks) {
|
|
1485
1486
|
const tracksPerGroup = {};
|
|
@@ -1496,18 +1497,13 @@ class KeyFramesTimeline extends Timeline {
|
|
|
1496
1497
|
else{ valueDim = 1; }
|
|
1497
1498
|
}
|
|
1498
1499
|
|
|
1499
|
-
let leftOver = values.length % valueDim; // just in case values have an incorrect length
|
|
1500
|
-
let amounEntries = Math.min( times.length, values.length - leftOver );
|
|
1501
|
-
times = times.slice(0, amounEntries);
|
|
1502
|
-
values = values.slice(0, amounEntries * valueDim);
|
|
1503
|
-
|
|
1504
1500
|
let baseName = track.id ?? track.name;
|
|
1505
1501
|
const [groupId, trackId] = baseName ? this._getValidTrackName(baseName) : [null, null];
|
|
1506
1502
|
|
|
1507
1503
|
const toInstantiate = Object.assign({}, track);
|
|
1508
1504
|
toInstantiate.id = trackId;
|
|
1509
1505
|
toInstantiate.dim = valueDim;
|
|
1510
|
-
const trackInfo = this.instantiateTrack(toInstantiate);
|
|
1506
|
+
const trackInfo = this.instantiateTrack(toInstantiate, clone);
|
|
1511
1507
|
|
|
1512
1508
|
// manual group insertion
|
|
1513
1509
|
if ( groupId ){
|
|
@@ -1525,13 +1521,34 @@ class KeyFramesTimeline extends Timeline {
|
|
|
1525
1521
|
|
|
1526
1522
|
animationClip.tracks.push(trackInfo);
|
|
1527
1523
|
|
|
1528
|
-
if ( times.length ){ duration = Math.max( duration, times[times.length-1]); }
|
|
1524
|
+
if ( trackInfo.times.length ){ duration = Math.max( duration, trackInfo.times[trackInfo.times.length-1]); }
|
|
1529
1525
|
}
|
|
1530
1526
|
|
|
1531
1527
|
animationClip.tracksPerGroup = tracksPerGroup;
|
|
1532
1528
|
if ( !animation || !animation.duration ){
|
|
1533
1529
|
animationClip.duration = duration;
|
|
1534
1530
|
}
|
|
1531
|
+
|
|
1532
|
+
// overwrite trackspergroup
|
|
1533
|
+
if ( animation.tracksPerGroup ){
|
|
1534
|
+
|
|
1535
|
+
// ungroup all tracks (just in case)
|
|
1536
|
+
animationClip.tracks.forEach( (v,i,arr) =>{ v.groupId = null; v.groupTrackIdx = -1; } );
|
|
1537
|
+
|
|
1538
|
+
animationClip.tracksPerGroup = {};
|
|
1539
|
+
let tpg = animation.tracksPerGroup;
|
|
1540
|
+
for( let groupId in tpg ){
|
|
1541
|
+
const source = tpg[groupId];
|
|
1542
|
+
const target = [];
|
|
1543
|
+
for( let ti = 0; ti < source.length; ++ti ){
|
|
1544
|
+
const trackInfo = animationClip.tracks[ source[ti].trackIdx ]; // redo references
|
|
1545
|
+
target[ti] = trackInfo;
|
|
1546
|
+
trackInfo.groupId = groupId;
|
|
1547
|
+
trackInfo.groupTrackIdx = ti; // index of track in group
|
|
1548
|
+
}
|
|
1549
|
+
animationClip.tracksPerGroup[ groupId ] = target;
|
|
1550
|
+
}
|
|
1551
|
+
}
|
|
1535
1552
|
}
|
|
1536
1553
|
|
|
1537
1554
|
return animationClip;
|
|
@@ -3042,6 +3059,10 @@ LX.KeyFramesTimeline = KeyFramesTimeline;
|
|
|
3042
3059
|
*/
|
|
3043
3060
|
|
|
3044
3061
|
class ClipsTimeline extends Timeline {
|
|
3062
|
+
static CLONEREASON_COPY = 1;
|
|
3063
|
+
static CLONEREASON_PASTE = 2;
|
|
3064
|
+
static CLONEREASON_HISTORY = 3;
|
|
3065
|
+
static CLONEREASON_TRACKCLONE = 4;
|
|
3045
3066
|
|
|
3046
3067
|
/**
|
|
3047
3068
|
* @param {string} name
|
|
@@ -3063,14 +3084,14 @@ class ClipsTimeline extends Timeline {
|
|
|
3063
3084
|
* @param {obj} animation data with which to generate an animationClip
|
|
3064
3085
|
* @returns
|
|
3065
3086
|
*/
|
|
3066
|
-
instantiateAnimationClip(animation) {
|
|
3087
|
+
instantiateAnimationClip(animation, clone = false) {
|
|
3067
3088
|
|
|
3068
3089
|
const animationClip = super.instantiateAnimationClip(animation);
|
|
3069
3090
|
|
|
3070
3091
|
if (animation && animation.tracks){
|
|
3071
3092
|
for( let i = 0; i < animation.tracks.length; ++i ) {
|
|
3072
3093
|
|
|
3073
|
-
const trackInfo = this.instantiateTrack( animation.tracks[i] );
|
|
3094
|
+
const trackInfo = this.instantiateTrack( animation.tracks[i], clone );
|
|
3074
3095
|
trackInfo.trackIdx = animationClip.tracks.length;
|
|
3075
3096
|
|
|
3076
3097
|
animationClip.tracks.push(trackInfo);
|
|
@@ -3080,6 +3101,47 @@ class ClipsTimeline extends Timeline {
|
|
|
3080
3101
|
return animationClip;
|
|
3081
3102
|
}
|
|
3082
3103
|
|
|
3104
|
+
/**
|
|
3105
|
+
*
|
|
3106
|
+
* @param {obj} options set some values for the track instance (groups and trackIdx not included)
|
|
3107
|
+
* @returns
|
|
3108
|
+
*/
|
|
3109
|
+
instantiateTrack(options = {}, clone = false) {
|
|
3110
|
+
const track = super.instantiateTrack(options);
|
|
3111
|
+
|
|
3112
|
+
track.trackIdx = this.animationClip.tracks.length;
|
|
3113
|
+
|
|
3114
|
+
track.selected = [];
|
|
3115
|
+
track.edited = [];
|
|
3116
|
+
track.hovered = [];
|
|
3117
|
+
|
|
3118
|
+
if( options.clips ){
|
|
3119
|
+
track.clips = clone ? this.cloneClips(options.clips, 0, ClipsTimeline.CLONEREASON_TRACKCLONE) : options.clips;
|
|
3120
|
+
}else{
|
|
3121
|
+
track.clips = [];
|
|
3122
|
+
}
|
|
3123
|
+
|
|
3124
|
+
const numClips = track.clips.length;
|
|
3125
|
+
|
|
3126
|
+
if ( options.selected && options.selected.length == numClips ){
|
|
3127
|
+
track.selected = clone ? options.selected.slice() : options.selected;
|
|
3128
|
+
}else{
|
|
3129
|
+
track.selected = (new Array(numClips)).fill(false);
|
|
3130
|
+
}
|
|
3131
|
+
if ( options.edited && options.edited.length == numClips ){
|
|
3132
|
+
track.edited = clone ? options.edited.slice() : options.edited;
|
|
3133
|
+
}else{
|
|
3134
|
+
track.edited = (new Array(numClips)).fill(false);
|
|
3135
|
+
}
|
|
3136
|
+
if ( options.hovered && options.hovered.length == numClips ){
|
|
3137
|
+
track.hovered = clone ? options.hovered.slice() : options.hovered;
|
|
3138
|
+
}else{
|
|
3139
|
+
track.hovered = (new Array(numClips)).fill(false);
|
|
3140
|
+
}
|
|
3141
|
+
|
|
3142
|
+
return track;
|
|
3143
|
+
}
|
|
3144
|
+
|
|
3083
3145
|
// use default updateleftpanel
|
|
3084
3146
|
// generateSelectedItemsTreeData(){}
|
|
3085
3147
|
|
|
@@ -3128,42 +3190,6 @@ class ClipsTimeline extends Timeline {
|
|
|
3128
3190
|
|
|
3129
3191
|
this.updateLeftPanel();
|
|
3130
3192
|
}
|
|
3131
|
-
|
|
3132
|
-
/**
|
|
3133
|
-
*
|
|
3134
|
-
* @param {obj} options set some values for the track instance (groups and trackIdx not included)
|
|
3135
|
-
* @returns
|
|
3136
|
-
*/
|
|
3137
|
-
instantiateTrack(options = {}) {
|
|
3138
|
-
const track = super.instantiateTrack(options);
|
|
3139
|
-
|
|
3140
|
-
track.trackIdx = this.animationClip.tracks.length;
|
|
3141
|
-
|
|
3142
|
-
track.clips = options.clips ?? [];
|
|
3143
|
-
track.selected = [];
|
|
3144
|
-
track.edited = [];
|
|
3145
|
-
track.hovered = [];
|
|
3146
|
-
|
|
3147
|
-
const numClips = track.clips.length;
|
|
3148
|
-
|
|
3149
|
-
if ( options.selected && options.selected.length == numClips ){
|
|
3150
|
-
track.selected = options.selected;
|
|
3151
|
-
}else{
|
|
3152
|
-
track.selected = (new Array(numClips)).fill(false);
|
|
3153
|
-
}
|
|
3154
|
-
if ( options.edited && options.edited.length == numClips ){
|
|
3155
|
-
track.edited = options.edited;
|
|
3156
|
-
}else{
|
|
3157
|
-
track.edited = (new Array(numClips)).fill(false);
|
|
3158
|
-
}
|
|
3159
|
-
if ( options.hovered && options.hovered.length == numClips ){
|
|
3160
|
-
track.hovered = options.hovered;
|
|
3161
|
-
}else{
|
|
3162
|
-
track.hovered = (new Array(numClips)).fill(false);
|
|
3163
|
-
}
|
|
3164
|
-
|
|
3165
|
-
return track;
|
|
3166
|
-
}
|
|
3167
3193
|
|
|
3168
3194
|
unHoverAll(){
|
|
3169
3195
|
if(this.lastHovered){
|
|
@@ -3236,6 +3262,10 @@ class ClipsTimeline extends Timeline {
|
|
|
3236
3262
|
let localY = e.localY;
|
|
3237
3263
|
let track = e.track;
|
|
3238
3264
|
|
|
3265
|
+
if ( e.button > 0 ){
|
|
3266
|
+
return;
|
|
3267
|
+
}
|
|
3268
|
+
|
|
3239
3269
|
if(e.ctrlKey && track) { // move clips
|
|
3240
3270
|
|
|
3241
3271
|
let x = e.offsetX;
|
|
@@ -3748,18 +3778,16 @@ class ClipsTimeline extends Timeline {
|
|
|
3748
3778
|
}
|
|
3749
3779
|
|
|
3750
3780
|
|
|
3751
|
-
|
|
3752
|
-
if( this.pixelsPerSecond < 200) {
|
|
3753
|
-
ctx.font = this.pixelsPerSecond * 0.06 +"px" + Timeline.FONT;
|
|
3754
|
-
}
|
|
3755
|
-
|
|
3756
|
-
const text = clip.id ?? ""; //clip.id.replaceAll("_", " ").replaceAll("-", " ");
|
|
3781
|
+
let text = clip.id ?? ""; //clip.id.replaceAll("_", " ").replaceAll("-", " ");
|
|
3757
3782
|
const textInfo = ctx.measureText( text );
|
|
3758
3783
|
|
|
3759
|
-
|
|
3760
|
-
if(
|
|
3761
|
-
|
|
3784
|
+
let textWidth = textInfo.width;
|
|
3785
|
+
if ( textWidth > w && textWidth > 0){
|
|
3786
|
+
let amount = Math.floor( w * text.length / textWidth );
|
|
3787
|
+
text = text.substr( 0, amount );
|
|
3788
|
+
textWidth = w;
|
|
3762
3789
|
}
|
|
3790
|
+
ctx.fillText( text, x + (w - textWidth)*0.5, y + offset + trackHeight * 0.5);
|
|
3763
3791
|
|
|
3764
3792
|
ctx.fillStyle = track.hovered[j] ? "white" : "#f5f5f5"//track.hovered[j] ? "white" : Timeline.FONT_COLOR_QUATERNARY;
|
|
3765
3793
|
ctx.strokeStyle = "rgba(125,125,125,0.4)";
|
|
@@ -4029,9 +4057,10 @@ class ClipsTimeline extends Timeline {
|
|
|
4029
4057
|
* User defined. Used when copying and pasting
|
|
4030
4058
|
* @param {Array of clips} clipsToClone array of original clips. Do not modify clips in this array
|
|
4031
4059
|
* @param {float} timeOffset Value of time that should be added (or subtracted) from the timing attributes
|
|
4060
|
+
* @param {int} reason Flag to signal the reason of the clone
|
|
4032
4061
|
* @returns {Array of clips}
|
|
4033
4062
|
*/
|
|
4034
|
-
cloneClips( clipsToClone, timeOffset ){
|
|
4063
|
+
cloneClips( clipsToClone, timeOffset, reason = 0 ){
|
|
4035
4064
|
let clipsToReturn = JSON.parse(JSON.stringify(clipsToClone))
|
|
4036
4065
|
for(let i = 0; i < clipsToReturn.length; ++i){
|
|
4037
4066
|
let clip = clipsToReturn[i];
|
|
@@ -4064,7 +4093,7 @@ class ClipsTimeline extends Timeline {
|
|
|
4064
4093
|
}
|
|
4065
4094
|
|
|
4066
4095
|
globalStart = Math.max(0, globalStart);
|
|
4067
|
-
this.clipboard = this.cloneClips( clipsToCopy, -globalStart );
|
|
4096
|
+
this.clipboard = this.cloneClips( clipsToCopy, -globalStart, ClipsTimeline.CLONEREASON_COPY );
|
|
4068
4097
|
}
|
|
4069
4098
|
|
|
4070
4099
|
pasteContent( time = this.currentTime ) {
|
|
@@ -4075,7 +4104,7 @@ class ClipsTimeline extends Timeline {
|
|
|
4075
4104
|
|
|
4076
4105
|
time = Math.max(0, time);
|
|
4077
4106
|
|
|
4078
|
-
let clipsToAdd = this.cloneClips( this.clipboard, time );
|
|
4107
|
+
let clipsToAdd = this.cloneClips( this.clipboard, time, ClipsTimeline.CLONEREASON_PASTE );
|
|
4079
4108
|
this.addClips(clipsToAdd, 0);
|
|
4080
4109
|
}
|
|
4081
4110
|
|
|
@@ -4124,7 +4153,7 @@ class ClipsTimeline extends Timeline {
|
|
|
4124
4153
|
*/
|
|
4125
4154
|
historyGenerateTrackStep( trackIdx ){
|
|
4126
4155
|
const track = this.animationClip.tracks[trackIdx];
|
|
4127
|
-
const clips = this.cloneClips(track.clips, 0);
|
|
4156
|
+
const clips = this.cloneClips(track.clips, 0, ClipsTimeline.CLONEREASON_HISTORY);
|
|
4128
4157
|
|
|
4129
4158
|
const undoStep = {
|
|
4130
4159
|
trackIdx: trackIdx, // already done by saveState
|
package/build/lexgui-docs.css
CHANGED
package/build/lexgui.css
CHANGED
|
@@ -3765,9 +3765,9 @@ meter:-moz-meter-sub-sub-optimum::-moz-meter-bar {
|
|
|
3765
3765
|
|
|
3766
3766
|
.lexlayers {
|
|
3767
3767
|
display: grid;
|
|
3768
|
-
grid-template-columns:
|
|
3768
|
+
grid-template-columns: repeat(auto-fit, minmax(18px, 1fr));
|
|
3769
3769
|
grid-gap: 6px 8px;
|
|
3770
|
-
|
|
3770
|
+
max-width: calc(26px * 8); /* 8 layers max */
|
|
3771
3771
|
}
|
|
3772
3772
|
|
|
3773
3773
|
.lexlayer {
|
|
@@ -3775,6 +3775,7 @@ meter:-moz-meter-sub-sub-optimum::-moz-meter-bar {
|
|
|
3775
3775
|
background-color: var(--layer-color);
|
|
3776
3776
|
color: var(--global-text-primary);
|
|
3777
3777
|
text-align: center;
|
|
3778
|
+
place-self: center;
|
|
3778
3779
|
line-height: 19px;
|
|
3779
3780
|
width: 18px;
|
|
3780
3781
|
height: 18px;
|
|
@@ -4585,9 +4586,10 @@ ul.lexassetscontent {
|
|
|
4585
4586
|
}
|
|
4586
4587
|
|
|
4587
4588
|
.lexassetscontent .lexitemdesc {
|
|
4588
|
-
position:
|
|
4589
|
+
position: fixed;
|
|
4589
4590
|
font-weight: 600;
|
|
4590
|
-
|
|
4591
|
+
white-space: nowrap;
|
|
4592
|
+
background-color: var(--global-text-secondary);
|
|
4591
4593
|
color: var(--global-color-primary);
|
|
4592
4594
|
font-size: var(--global-font-size);
|
|
4593
4595
|
border-radius: 6px;
|
|
@@ -4769,6 +4771,39 @@ ul.lexassetscontent {
|
|
|
4769
4771
|
transform: scale(1.12);
|
|
4770
4772
|
}
|
|
4771
4773
|
|
|
4774
|
+
/* Tour */
|
|
4775
|
+
|
|
4776
|
+
.tour-mask {
|
|
4777
|
+
position: absolute;
|
|
4778
|
+
top: 0; left: 0; right: 0; bottom: 0;
|
|
4779
|
+
background-color: #1f1f1fe7;
|
|
4780
|
+
--webkit-backdrop-filter: blur(2px);
|
|
4781
|
+
backdrop-filter: blur(2px);
|
|
4782
|
+
z-index: 99;
|
|
4783
|
+
clip-path: url(#svgTourClipPath);
|
|
4784
|
+
}
|
|
4785
|
+
|
|
4786
|
+
.tour-ref-mask {
|
|
4787
|
+
position: absolute;
|
|
4788
|
+
background-color: #1f1f1fe7;
|
|
4789
|
+
--webkit-backdrop-filter: blur(2px);
|
|
4790
|
+
backdrop-filter: blur(2px);
|
|
4791
|
+
z-index: 100;
|
|
4792
|
+
mask: url(#svgTourReferenceMask);
|
|
4793
|
+
}
|
|
4794
|
+
|
|
4795
|
+
.tour-step-indicator {
|
|
4796
|
+
width: 10px;
|
|
4797
|
+
height: 10px;
|
|
4798
|
+
border-radius: 5px;
|
|
4799
|
+
background-color: var(--global-text-quaternary);
|
|
4800
|
+
display: inline-flex;
|
|
4801
|
+
}
|
|
4802
|
+
|
|
4803
|
+
.tour-step-indicator.active {
|
|
4804
|
+
background-color: var(--global-text-primary);
|
|
4805
|
+
}
|
|
4806
|
+
|
|
4772
4807
|
/* Code Editor */
|
|
4773
4808
|
.codebasearea {
|
|
4774
4809
|
display: flex;
|