@playcanvas/web-components 0.15.0 → 0.16.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/components/anim-clip.d.cts +127 -0
- package/dist/components/anim-clip.d.ts +127 -0
- package/dist/components/anim-component.d.cts +207 -0
- package/dist/components/anim-component.d.ts +207 -0
- package/dist/custom-elements.json +532 -0
- package/dist/index.d.cts +5 -1
- package/dist/index.d.ts +5 -1
- package/dist/pwc.cjs +1527 -638
- package/dist/pwc.cjs.map +1 -1
- package/dist/pwc.js +1527 -638
- package/dist/pwc.js.map +1 -1
- package/dist/pwc.min.js +1 -1
- package/dist/pwc.min.js.map +1 -1
- package/dist/pwc.min.mjs +1 -1
- package/dist/pwc.min.mjs.map +1 -1
- package/dist/pwc.mjs +1527 -640
- package/dist/pwc.mjs.map +1 -1
- package/dist/vscode.html-custom-data.json +59 -0
- package/dist/web-types.json +156 -1
- package/package.json +1 -1
- package/src/components/anim-clip.ts +395 -0
- package/src/components/anim-component.ts +649 -0
- package/src/index.ts +6 -0
- package/src/model.ts +0 -7
|
@@ -1554,6 +1554,22 @@
|
|
|
1554
1554
|
"module": "src/index.ts"
|
|
1555
1555
|
}
|
|
1556
1556
|
},
|
|
1557
|
+
{
|
|
1558
|
+
"kind": "js",
|
|
1559
|
+
"name": "AnimComponentElement",
|
|
1560
|
+
"declaration": {
|
|
1561
|
+
"name": "AnimComponentElement",
|
|
1562
|
+
"module": "src/index.ts"
|
|
1563
|
+
}
|
|
1564
|
+
},
|
|
1565
|
+
{
|
|
1566
|
+
"kind": "js",
|
|
1567
|
+
"name": "AnimClipElement",
|
|
1568
|
+
"declaration": {
|
|
1569
|
+
"name": "AnimClipElement",
|
|
1570
|
+
"module": "src/index.ts"
|
|
1571
|
+
}
|
|
1572
|
+
},
|
|
1557
1573
|
{
|
|
1558
1574
|
"kind": "js",
|
|
1559
1575
|
"name": "ButtonComponentElement",
|
|
@@ -5378,6 +5394,522 @@
|
|
|
5378
5394
|
}
|
|
5379
5395
|
]
|
|
5380
5396
|
},
|
|
5397
|
+
{
|
|
5398
|
+
"kind": "javascript-module",
|
|
5399
|
+
"path": "src/components/anim-clip.ts",
|
|
5400
|
+
"declarations": [
|
|
5401
|
+
{
|
|
5402
|
+
"kind": "class",
|
|
5403
|
+
"description": "The AnimClipElement interface provides properties and methods for manipulating\n[`<pc-anim-clip>`](https://developer.playcanvas.com/user-manual/web-components/tags/pc-anim-clip/)\nelements. The AnimClipElement interface also inherits the properties and methods of the\nHTMLElement interface.\n\nA clip declares one named animation on its parent `<pc-anim>`. `name` is both the clip's name\nand the track looked up in the clip's source: an explicit `asset` (a `container`, an\n`animation` `.glb`, or an `animclip` JSON), or, without one, the container of the `<pc-model>`\nenclosing the parent `<pc-anim>`. A source holding a single track supplies it whatever it is\nnamed; in a multi-track source the track named `name` is chosen, falling back to the first\nwith a warning. The element becomes ready once its resolved track is assigned.\n",
|
|
5404
|
+
"name": "AnimClipElement",
|
|
5405
|
+
"members": [
|
|
5406
|
+
{
|
|
5407
|
+
"kind": "field",
|
|
5408
|
+
"name": "asset",
|
|
5409
|
+
"description": "Gets the id of the `pc-asset` supplying the clip's track.",
|
|
5410
|
+
"parameters": [
|
|
5411
|
+
{
|
|
5412
|
+
"description": "The asset id.",
|
|
5413
|
+
"name": "value"
|
|
5414
|
+
}
|
|
5415
|
+
],
|
|
5416
|
+
"return": {
|
|
5417
|
+
"type": {
|
|
5418
|
+
"text": ""
|
|
5419
|
+
}
|
|
5420
|
+
}
|
|
5421
|
+
},
|
|
5422
|
+
{
|
|
5423
|
+
"kind": "field",
|
|
5424
|
+
"name": "closestApp",
|
|
5425
|
+
"type": {
|
|
5426
|
+
"text": "AppElement | null"
|
|
5427
|
+
},
|
|
5428
|
+
"description": "The nearest ancestor `<pc-app>` element, or `null` if this element has no `<pc-app>`\nancestor. The search starts at the parent, so an element never resolves to itself.",
|
|
5429
|
+
"return": {
|
|
5430
|
+
"type": {
|
|
5431
|
+
"text": ""
|
|
5432
|
+
}
|
|
5433
|
+
},
|
|
5434
|
+
"readonly": true,
|
|
5435
|
+
"inheritedFrom": {
|
|
5436
|
+
"name": "AsyncElement",
|
|
5437
|
+
"module": "src/async-element.ts"
|
|
5438
|
+
}
|
|
5439
|
+
},
|
|
5440
|
+
{
|
|
5441
|
+
"kind": "field",
|
|
5442
|
+
"name": "closestEntity",
|
|
5443
|
+
"type": {
|
|
5444
|
+
"text": "EntityBaseElement | null"
|
|
5445
|
+
},
|
|
5446
|
+
"description": "The nearest ancestor element that fronts an entity — `<pc-entity>` or `<pc-node>` — or\n`null` if this element has no such ancestor. The search starts at the parent, so an element\nnever resolves to itself.",
|
|
5447
|
+
"return": {
|
|
5448
|
+
"type": {
|
|
5449
|
+
"text": ""
|
|
5450
|
+
}
|
|
5451
|
+
},
|
|
5452
|
+
"readonly": true,
|
|
5453
|
+
"inheritedFrom": {
|
|
5454
|
+
"name": "AsyncElement",
|
|
5455
|
+
"module": "src/async-element.ts"
|
|
5456
|
+
}
|
|
5457
|
+
},
|
|
5458
|
+
{
|
|
5459
|
+
"kind": "field",
|
|
5460
|
+
"name": "loop",
|
|
5461
|
+
"description": "Gets whether the clip loops.",
|
|
5462
|
+
"parameters": [
|
|
5463
|
+
{
|
|
5464
|
+
"description": "Whether the clip loops.",
|
|
5465
|
+
"name": "value"
|
|
5466
|
+
}
|
|
5467
|
+
],
|
|
5468
|
+
"return": {
|
|
5469
|
+
"type": {
|
|
5470
|
+
"text": ""
|
|
5471
|
+
}
|
|
5472
|
+
}
|
|
5473
|
+
},
|
|
5474
|
+
{
|
|
5475
|
+
"kind": "field",
|
|
5476
|
+
"name": "name",
|
|
5477
|
+
"description": "Gets the name of the clip.",
|
|
5478
|
+
"parameters": [
|
|
5479
|
+
{
|
|
5480
|
+
"description": "The clip name.",
|
|
5481
|
+
"name": "value"
|
|
5482
|
+
}
|
|
5483
|
+
],
|
|
5484
|
+
"return": {
|
|
5485
|
+
"type": {
|
|
5486
|
+
"text": ""
|
|
5487
|
+
}
|
|
5488
|
+
}
|
|
5489
|
+
},
|
|
5490
|
+
{
|
|
5491
|
+
"kind": "method",
|
|
5492
|
+
"name": "ready",
|
|
5493
|
+
"return": {
|
|
5494
|
+
"type": {
|
|
5495
|
+
"text": ""
|
|
5496
|
+
}
|
|
5497
|
+
},
|
|
5498
|
+
"description": "Returns a promise that resolves with this element when it's ready. This is the low-level\nprimitive underlying whenReady, which is the recommended way to wait for elements.\n\nReadiness tracks the element's current lifecycle: once a ready element is torn down (for\nexample by removing it from the document), this returns a fresh promise that resolves when\nthe element is next ready. A promise obtained earlier stays resolved — call this again\nafter re-inserting an element rather than reusing a promise from before its removal.",
|
|
5499
|
+
"inheritedFrom": {
|
|
5500
|
+
"name": "AsyncElement",
|
|
5501
|
+
"module": "src/async-element.ts"
|
|
5502
|
+
}
|
|
5503
|
+
},
|
|
5504
|
+
{
|
|
5505
|
+
"kind": "field",
|
|
5506
|
+
"name": "speed",
|
|
5507
|
+
"description": "Gets the playback speed of the clip.",
|
|
5508
|
+
"parameters": [
|
|
5509
|
+
{
|
|
5510
|
+
"description": "The playback speed.",
|
|
5511
|
+
"name": "value"
|
|
5512
|
+
}
|
|
5513
|
+
],
|
|
5514
|
+
"return": {
|
|
5515
|
+
"type": {
|
|
5516
|
+
"text": ""
|
|
5517
|
+
}
|
|
5518
|
+
}
|
|
5519
|
+
}
|
|
5520
|
+
],
|
|
5521
|
+
"attributes": [
|
|
5522
|
+
{
|
|
5523
|
+
"name": "asset",
|
|
5524
|
+
"type": {
|
|
5525
|
+
"text": "string"
|
|
5526
|
+
},
|
|
5527
|
+
"fieldName": "asset",
|
|
5528
|
+
"description": "The id of the `pc-asset` supplying the clip's track."
|
|
5529
|
+
},
|
|
5530
|
+
{
|
|
5531
|
+
"name": "loop",
|
|
5532
|
+
"type": {
|
|
5533
|
+
"text": "boolean"
|
|
5534
|
+
},
|
|
5535
|
+
"fieldName": "loop",
|
|
5536
|
+
"default": "true",
|
|
5537
|
+
"description": "Whether the clip loops."
|
|
5538
|
+
},
|
|
5539
|
+
{
|
|
5540
|
+
"name": "name",
|
|
5541
|
+
"type": {
|
|
5542
|
+
"text": "string"
|
|
5543
|
+
},
|
|
5544
|
+
"fieldName": "name",
|
|
5545
|
+
"description": "The name of the clip."
|
|
5546
|
+
},
|
|
5547
|
+
{
|
|
5548
|
+
"name": "speed",
|
|
5549
|
+
"type": {
|
|
5550
|
+
"text": "number"
|
|
5551
|
+
},
|
|
5552
|
+
"fieldName": "speed",
|
|
5553
|
+
"default": "1",
|
|
5554
|
+
"description": "The playback speed of the clip."
|
|
5555
|
+
}
|
|
5556
|
+
],
|
|
5557
|
+
"superclass": {
|
|
5558
|
+
"name": "AsyncElement",
|
|
5559
|
+
"module": "/src/async-element"
|
|
5560
|
+
},
|
|
5561
|
+
"tagName": "pc-anim-clip",
|
|
5562
|
+
"customElement": true,
|
|
5563
|
+
"events": [
|
|
5564
|
+
{
|
|
5565
|
+
"name": "ready",
|
|
5566
|
+
"type": {
|
|
5567
|
+
"text": "CustomEvent"
|
|
5568
|
+
},
|
|
5569
|
+
"description": "Fired when the element is fully initialized — once per readiness cycle, so an element that is torn down and re-initialized (for example by removing and re-inserting it) fires it again. Bubbles and is composed.",
|
|
5570
|
+
"inheritedFrom": {
|
|
5571
|
+
"name": "AsyncElement",
|
|
5572
|
+
"module": "src/async-element.ts"
|
|
5573
|
+
}
|
|
5574
|
+
}
|
|
5575
|
+
]
|
|
5576
|
+
}
|
|
5577
|
+
],
|
|
5578
|
+
"exports": [
|
|
5579
|
+
{
|
|
5580
|
+
"kind": "custom-element-definition",
|
|
5581
|
+
"name": "pc-anim-clip",
|
|
5582
|
+
"declaration": {
|
|
5583
|
+
"name": "AnimClipElement",
|
|
5584
|
+
"module": "src/components/anim-clip.ts"
|
|
5585
|
+
}
|
|
5586
|
+
},
|
|
5587
|
+
{
|
|
5588
|
+
"kind": "js",
|
|
5589
|
+
"name": "AnimClipElement",
|
|
5590
|
+
"declaration": {
|
|
5591
|
+
"name": "AnimClipElement",
|
|
5592
|
+
"module": "src/components/anim-clip.ts"
|
|
5593
|
+
}
|
|
5594
|
+
}
|
|
5595
|
+
]
|
|
5596
|
+
},
|
|
5597
|
+
{
|
|
5598
|
+
"kind": "javascript-module",
|
|
5599
|
+
"path": "src/components/anim-component.ts",
|
|
5600
|
+
"declarations": [
|
|
5601
|
+
{
|
|
5602
|
+
"kind": "class",
|
|
5603
|
+
"description": "The AnimComponentElement interface provides properties and methods for manipulating\n[`<pc-anim>`](https://developer.playcanvas.com/user-manual/web-components/tags/pc-anim/) elements.\nThe AnimComponentElement interface also inherits the properties and methods of the\nHTMLElement interface.\n\nThe element drives animation clips over the host entity's hierarchy. Clips come from\n`<pc-anim-clip>` children — or, when the element is a direct child of a `<pc-model>` and\ndeclares no clips, every animation of that model's container asset is assigned, named by track\nname, in container order. The first clip plays automatically (opt out with `activate=\"false\"`);\nswitch clips declaratively through the `clip` attribute, or imperatively through play\nand transition. Tracks bind to scene nodes by name, so any hierarchy whose node names\nmatch a clip's curves can be animated — a model's skeleton is simply the common case.\n\nThe engine reports no clip completion: a non-looping clip holds its last pose silently. Poll\nthe underlying AnimComponent (via component) for playback state beyond what\nthis element exposes.\n",
|
|
5604
|
+
"name": "AnimComponentElement",
|
|
5605
|
+
"members": [
|
|
5606
|
+
{
|
|
5607
|
+
"kind": "field",
|
|
5608
|
+
"name": "activate",
|
|
5609
|
+
"description": "Gets whether playback starts automatically once a clip is assigned.",
|
|
5610
|
+
"parameters": [
|
|
5611
|
+
{
|
|
5612
|
+
"description": "Whether playback starts automatically.",
|
|
5613
|
+
"name": "value"
|
|
5614
|
+
}
|
|
5615
|
+
],
|
|
5616
|
+
"return": {
|
|
5617
|
+
"type": {
|
|
5618
|
+
"text": ""
|
|
5619
|
+
}
|
|
5620
|
+
}
|
|
5621
|
+
},
|
|
5622
|
+
{
|
|
5623
|
+
"kind": "field",
|
|
5624
|
+
"name": "clip",
|
|
5625
|
+
"description": "Gets the name of the active clip.",
|
|
5626
|
+
"parameters": [
|
|
5627
|
+
{
|
|
5628
|
+
"description": "The name of the active clip.",
|
|
5629
|
+
"name": "value"
|
|
5630
|
+
}
|
|
5631
|
+
],
|
|
5632
|
+
"return": {
|
|
5633
|
+
"type": {
|
|
5634
|
+
"text": ""
|
|
5635
|
+
}
|
|
5636
|
+
}
|
|
5637
|
+
},
|
|
5638
|
+
{
|
|
5639
|
+
"kind": "field",
|
|
5640
|
+
"name": "clips",
|
|
5641
|
+
"type": {
|
|
5642
|
+
"text": "string[]"
|
|
5643
|
+
},
|
|
5644
|
+
"description": "Gets the names of the assigned clips.",
|
|
5645
|
+
"return": {
|
|
5646
|
+
"type": {
|
|
5647
|
+
"text": ""
|
|
5648
|
+
}
|
|
5649
|
+
},
|
|
5650
|
+
"readonly": true
|
|
5651
|
+
},
|
|
5652
|
+
{
|
|
5653
|
+
"kind": "field",
|
|
5654
|
+
"name": "closestApp",
|
|
5655
|
+
"type": {
|
|
5656
|
+
"text": "AppElement | null"
|
|
5657
|
+
},
|
|
5658
|
+
"description": "The nearest ancestor `<pc-app>` element, or `null` if this element has no `<pc-app>`\nancestor. The search starts at the parent, so an element never resolves to itself.",
|
|
5659
|
+
"return": {
|
|
5660
|
+
"type": {
|
|
5661
|
+
"text": ""
|
|
5662
|
+
}
|
|
5663
|
+
},
|
|
5664
|
+
"readonly": true,
|
|
5665
|
+
"inheritedFrom": {
|
|
5666
|
+
"name": "AsyncElement",
|
|
5667
|
+
"module": "src/async-element.ts"
|
|
5668
|
+
}
|
|
5669
|
+
},
|
|
5670
|
+
{
|
|
5671
|
+
"kind": "field",
|
|
5672
|
+
"name": "closestEntity",
|
|
5673
|
+
"type": {
|
|
5674
|
+
"text": "EntityBaseElement | null"
|
|
5675
|
+
},
|
|
5676
|
+
"description": "The nearest ancestor element that fronts an entity — `<pc-entity>` or `<pc-node>` — or\n`null` if this element has no such ancestor. The search starts at the parent, so an element\nnever resolves to itself.",
|
|
5677
|
+
"return": {
|
|
5678
|
+
"type": {
|
|
5679
|
+
"text": ""
|
|
5680
|
+
}
|
|
5681
|
+
},
|
|
5682
|
+
"readonly": true,
|
|
5683
|
+
"inheritedFrom": {
|
|
5684
|
+
"name": "AsyncElement",
|
|
5685
|
+
"module": "src/async-element.ts"
|
|
5686
|
+
}
|
|
5687
|
+
},
|
|
5688
|
+
{
|
|
5689
|
+
"kind": "field",
|
|
5690
|
+
"name": "component",
|
|
5691
|
+
"type": {
|
|
5692
|
+
"text": "Component | null"
|
|
5693
|
+
},
|
|
5694
|
+
"description": "Gets the underlying PlayCanvas anim component.",
|
|
5695
|
+
"return": {
|
|
5696
|
+
"type": {
|
|
5697
|
+
"text": ""
|
|
5698
|
+
}
|
|
5699
|
+
},
|
|
5700
|
+
"readonly": true,
|
|
5701
|
+
"inheritedFrom": {
|
|
5702
|
+
"name": "ComponentElement",
|
|
5703
|
+
"module": "src/components/component.ts"
|
|
5704
|
+
}
|
|
5705
|
+
},
|
|
5706
|
+
{
|
|
5707
|
+
"kind": "field",
|
|
5708
|
+
"name": "enabled",
|
|
5709
|
+
"description": "Gets the enabled state of the component.",
|
|
5710
|
+
"parameters": [
|
|
5711
|
+
{
|
|
5712
|
+
"description": "The enabled state of the component.",
|
|
5713
|
+
"name": "value"
|
|
5714
|
+
}
|
|
5715
|
+
],
|
|
5716
|
+
"return": {
|
|
5717
|
+
"type": {
|
|
5718
|
+
"text": ""
|
|
5719
|
+
}
|
|
5720
|
+
},
|
|
5721
|
+
"inheritedFrom": {
|
|
5722
|
+
"name": "ComponentElement",
|
|
5723
|
+
"module": "src/components/component.ts"
|
|
5724
|
+
}
|
|
5725
|
+
},
|
|
5726
|
+
{
|
|
5727
|
+
"kind": "method",
|
|
5728
|
+
"name": "pause",
|
|
5729
|
+
"description": "Pauses playback, preserving the playhead — play resumes from where it stopped."
|
|
5730
|
+
},
|
|
5731
|
+
{
|
|
5732
|
+
"kind": "method",
|
|
5733
|
+
"name": "play",
|
|
5734
|
+
"parameters": [
|
|
5735
|
+
{
|
|
5736
|
+
"name": "name",
|
|
5737
|
+
"optional": true,
|
|
5738
|
+
"type": {
|
|
5739
|
+
"text": "string"
|
|
5740
|
+
},
|
|
5741
|
+
"description": "The name of the clip to play. Resumes the current clip when omitted."
|
|
5742
|
+
}
|
|
5743
|
+
],
|
|
5744
|
+
"description": "Resumes playback, optionally switching to a named clip first (a hard cut). A name that\nmatches no clip leaves the selection unchanged."
|
|
5745
|
+
},
|
|
5746
|
+
{
|
|
5747
|
+
"kind": "method",
|
|
5748
|
+
"name": "ready",
|
|
5749
|
+
"return": {
|
|
5750
|
+
"type": {
|
|
5751
|
+
"text": ""
|
|
5752
|
+
}
|
|
5753
|
+
},
|
|
5754
|
+
"description": "Returns a promise that resolves with this element when it's ready. This is the low-level\nprimitive underlying whenReady, which is the recommended way to wait for elements.\n\nReadiness tracks the element's current lifecycle: once a ready element is torn down (for\nexample by removing it from the document), this returns a fresh promise that resolves when\nthe element is next ready. A promise obtained earlier stays resolved — call this again\nafter re-inserting an element rather than reusing a promise from before its removal.",
|
|
5755
|
+
"inheritedFrom": {
|
|
5756
|
+
"name": "AsyncElement",
|
|
5757
|
+
"module": "src/async-element.ts"
|
|
5758
|
+
}
|
|
5759
|
+
},
|
|
5760
|
+
{
|
|
5761
|
+
"kind": "field",
|
|
5762
|
+
"name": "speed",
|
|
5763
|
+
"description": "Gets the playback speed multiplier applied across all clips.",
|
|
5764
|
+
"parameters": [
|
|
5765
|
+
{
|
|
5766
|
+
"description": "The playback speed multiplier.",
|
|
5767
|
+
"name": "value"
|
|
5768
|
+
}
|
|
5769
|
+
],
|
|
5770
|
+
"return": {
|
|
5771
|
+
"type": {
|
|
5772
|
+
"text": ""
|
|
5773
|
+
}
|
|
5774
|
+
}
|
|
5775
|
+
},
|
|
5776
|
+
{
|
|
5777
|
+
"kind": "method",
|
|
5778
|
+
"name": "transition",
|
|
5779
|
+
"parameters": [
|
|
5780
|
+
{
|
|
5781
|
+
"name": "name",
|
|
5782
|
+
"type": {
|
|
5783
|
+
"text": "string"
|
|
5784
|
+
},
|
|
5785
|
+
"description": "The name of the clip to fade to."
|
|
5786
|
+
},
|
|
5787
|
+
{
|
|
5788
|
+
"name": "time",
|
|
5789
|
+
"optional": true,
|
|
5790
|
+
"type": {
|
|
5791
|
+
"text": "number"
|
|
5792
|
+
},
|
|
5793
|
+
"description": "The fade duration in seconds. Defaults to the `transition-time` attribute."
|
|
5794
|
+
}
|
|
5795
|
+
],
|
|
5796
|
+
"description": "Cross-fades to a named clip and ensures playback is running. A name that matches no clip\nleaves the selection unchanged."
|
|
5797
|
+
},
|
|
5798
|
+
{
|
|
5799
|
+
"kind": "field",
|
|
5800
|
+
"name": "transitionTime",
|
|
5801
|
+
"description": "Gets the cross-fade duration of clip switches made through the `clip` attribute.",
|
|
5802
|
+
"parameters": [
|
|
5803
|
+
{
|
|
5804
|
+
"description": "The cross-fade duration in seconds.",
|
|
5805
|
+
"name": "value"
|
|
5806
|
+
}
|
|
5807
|
+
],
|
|
5808
|
+
"return": {
|
|
5809
|
+
"type": {
|
|
5810
|
+
"text": ""
|
|
5811
|
+
}
|
|
5812
|
+
}
|
|
5813
|
+
}
|
|
5814
|
+
],
|
|
5815
|
+
"attributes": [
|
|
5816
|
+
{
|
|
5817
|
+
"name": "activate",
|
|
5818
|
+
"type": {
|
|
5819
|
+
"text": "boolean"
|
|
5820
|
+
},
|
|
5821
|
+
"fieldName": "activate",
|
|
5822
|
+
"default": "true",
|
|
5823
|
+
"description": "Whether playback starts automatically once a clip is assigned."
|
|
5824
|
+
},
|
|
5825
|
+
{
|
|
5826
|
+
"name": "clip",
|
|
5827
|
+
"type": {
|
|
5828
|
+
"text": "string"
|
|
5829
|
+
},
|
|
5830
|
+
"fieldName": "clip",
|
|
5831
|
+
"description": "The name of the active clip."
|
|
5832
|
+
},
|
|
5833
|
+
{
|
|
5834
|
+
"name": "enabled",
|
|
5835
|
+
"type": {
|
|
5836
|
+
"text": "boolean"
|
|
5837
|
+
},
|
|
5838
|
+
"fieldName": "enabled",
|
|
5839
|
+
"default": "true",
|
|
5840
|
+
"description": "The enabled state of the component.",
|
|
5841
|
+
"inheritedFrom": {
|
|
5842
|
+
"name": "ComponentElement",
|
|
5843
|
+
"module": "src/components/component.ts"
|
|
5844
|
+
}
|
|
5845
|
+
},
|
|
5846
|
+
{
|
|
5847
|
+
"name": "speed",
|
|
5848
|
+
"type": {
|
|
5849
|
+
"text": "number"
|
|
5850
|
+
},
|
|
5851
|
+
"fieldName": "speed",
|
|
5852
|
+
"default": "1",
|
|
5853
|
+
"description": "The playback speed multiplier applied across all clips."
|
|
5854
|
+
},
|
|
5855
|
+
{
|
|
5856
|
+
"name": "transition-time",
|
|
5857
|
+
"type": {
|
|
5858
|
+
"text": "number"
|
|
5859
|
+
},
|
|
5860
|
+
"fieldName": "transitionTime",
|
|
5861
|
+
"default": "0",
|
|
5862
|
+
"description": "The cross-fade duration of clip switches made through the `clip` attribute."
|
|
5863
|
+
}
|
|
5864
|
+
],
|
|
5865
|
+
"superclass": {
|
|
5866
|
+
"name": "ComponentElement",
|
|
5867
|
+
"module": "/src/components/component"
|
|
5868
|
+
},
|
|
5869
|
+
"tagName": "pc-anim",
|
|
5870
|
+
"customElement": true,
|
|
5871
|
+
"events": [
|
|
5872
|
+
{
|
|
5873
|
+
"name": "ready",
|
|
5874
|
+
"type": {
|
|
5875
|
+
"text": "CustomEvent"
|
|
5876
|
+
},
|
|
5877
|
+
"description": "Fired when the element is fully initialized — once per readiness cycle, so an element that is torn down and re-initialized (for example by removing and re-inserting it) fires it again. Bubbles and is composed.",
|
|
5878
|
+
"inheritedFrom": {
|
|
5879
|
+
"name": "AsyncElement",
|
|
5880
|
+
"module": "src/async-element.ts"
|
|
5881
|
+
}
|
|
5882
|
+
}
|
|
5883
|
+
]
|
|
5884
|
+
}
|
|
5885
|
+
],
|
|
5886
|
+
"exports": [
|
|
5887
|
+
{
|
|
5888
|
+
"kind": "custom-element-definition",
|
|
5889
|
+
"name": "pc-anim",
|
|
5890
|
+
"declaration": {
|
|
5891
|
+
"name": "AnimComponentElement",
|
|
5892
|
+
"module": "src/components/anim-component.ts"
|
|
5893
|
+
}
|
|
5894
|
+
},
|
|
5895
|
+
{
|
|
5896
|
+
"kind": "js",
|
|
5897
|
+
"name": "AnimComponentElement",
|
|
5898
|
+
"declaration": {
|
|
5899
|
+
"name": "AnimComponentElement",
|
|
5900
|
+
"module": "src/components/anim-component.ts"
|
|
5901
|
+
}
|
|
5902
|
+
},
|
|
5903
|
+
{
|
|
5904
|
+
"kind": "js",
|
|
5905
|
+
"name": "ContainerWithAnimations",
|
|
5906
|
+
"declaration": {
|
|
5907
|
+
"name": "ContainerWithAnimations",
|
|
5908
|
+
"module": "src/components/anim-component.ts"
|
|
5909
|
+
}
|
|
5910
|
+
}
|
|
5911
|
+
]
|
|
5912
|
+
},
|
|
5381
5913
|
{
|
|
5382
5914
|
"kind": "javascript-module",
|
|
5383
5915
|
"path": "src/components/button-component.ts",
|
package/dist/index.d.cts
CHANGED
|
@@ -11,6 +11,8 @@ import { ModuleElement } from './module.cjs';
|
|
|
11
11
|
import { AppElement } from './app.cjs';
|
|
12
12
|
import { EntityElement } from './entity.cjs';
|
|
13
13
|
import { AssetElement } from './asset.cjs';
|
|
14
|
+
import { AnimComponentElement } from './components/anim-component.cjs';
|
|
15
|
+
import { AnimClipElement } from './components/anim-clip.cjs';
|
|
14
16
|
import { ListenerComponentElement } from './components/listener-component.cjs';
|
|
15
17
|
import { ButtonComponentElement } from './components/button-component.cjs';
|
|
16
18
|
import { CameraComponentElement } from './components/camera-component.cjs';
|
|
@@ -47,6 +49,8 @@ declare global {
|
|
|
47
49
|
scriptnamechange: ScriptNameChangeEvent;
|
|
48
50
|
}
|
|
49
51
|
interface HTMLElementTagNameMap {
|
|
52
|
+
'pc-anim': AnimComponentElement;
|
|
53
|
+
'pc-anim-clip': AnimClipElement;
|
|
50
54
|
'pc-app': AppElement;
|
|
51
55
|
'pc-asset': AssetElement;
|
|
52
56
|
'pc-button': ButtonComponentElement;
|
|
@@ -78,7 +82,7 @@ declare global {
|
|
|
78
82
|
'pc-sounds': SoundComponentElement;
|
|
79
83
|
}
|
|
80
84
|
}
|
|
81
|
-
export { AsyncElement, ModuleElement, AppElement, EntityElement, AssetElement, ButtonComponentElement, CameraComponentElement, CollisionComponentElement, ComponentElement, ElementComponentElement, JointComponentElement, LayoutChildComponentElement, LayoutGroupComponentElement, ParticleSystemComponentElement, LightComponentElement, ListenerComponentElement, RenderComponentElement, RigidBodyComponentElement, ScreenComponentElement, ScrollbarComponentElement, ScrollViewComponentElement, ScriptComponentElement, ScriptElement, SoundComponentElement, SoundSlotElement, GSplatComponentElement, EntityBaseElement, MaterialElement, ModelElement, NodeElement, SceneElement, SkyElement, whenReady };
|
|
85
|
+
export { AsyncElement, ModuleElement, AppElement, EntityElement, AssetElement, AnimComponentElement, AnimClipElement, ButtonComponentElement, CameraComponentElement, CollisionComponentElement, ComponentElement, ElementComponentElement, JointComponentElement, LayoutChildComponentElement, LayoutGroupComponentElement, ParticleSystemComponentElement, LightComponentElement, ListenerComponentElement, RenderComponentElement, RigidBodyComponentElement, ScreenComponentElement, ScrollbarComponentElement, ScrollViewComponentElement, ScriptComponentElement, ScriptElement, SoundComponentElement, SoundSlotElement, GSplatComponentElement, EntityBaseElement, MaterialElement, ModelElement, NodeElement, SceneElement, SkyElement, whenReady };
|
|
82
86
|
export type { AsyncElementTagName } from './async-element.cjs';
|
|
83
87
|
export type { HierarchyMaterial, HierarchyNode } from './model.cjs';
|
|
84
88
|
export type { MaterialOverrides } from './node.cjs';
|
package/dist/index.d.ts
CHANGED
|
@@ -11,6 +11,8 @@ import { ModuleElement } from './module.js';
|
|
|
11
11
|
import { AppElement } from './app.js';
|
|
12
12
|
import { EntityElement } from './entity.js';
|
|
13
13
|
import { AssetElement } from './asset.js';
|
|
14
|
+
import { AnimComponentElement } from './components/anim-component.js';
|
|
15
|
+
import { AnimClipElement } from './components/anim-clip.js';
|
|
14
16
|
import { ListenerComponentElement } from './components/listener-component.js';
|
|
15
17
|
import { ButtonComponentElement } from './components/button-component.js';
|
|
16
18
|
import { CameraComponentElement } from './components/camera-component.js';
|
|
@@ -47,6 +49,8 @@ declare global {
|
|
|
47
49
|
scriptnamechange: ScriptNameChangeEvent;
|
|
48
50
|
}
|
|
49
51
|
interface HTMLElementTagNameMap {
|
|
52
|
+
'pc-anim': AnimComponentElement;
|
|
53
|
+
'pc-anim-clip': AnimClipElement;
|
|
50
54
|
'pc-app': AppElement;
|
|
51
55
|
'pc-asset': AssetElement;
|
|
52
56
|
'pc-button': ButtonComponentElement;
|
|
@@ -78,7 +82,7 @@ declare global {
|
|
|
78
82
|
'pc-sounds': SoundComponentElement;
|
|
79
83
|
}
|
|
80
84
|
}
|
|
81
|
-
export { AsyncElement, ModuleElement, AppElement, EntityElement, AssetElement, ButtonComponentElement, CameraComponentElement, CollisionComponentElement, ComponentElement, ElementComponentElement, JointComponentElement, LayoutChildComponentElement, LayoutGroupComponentElement, ParticleSystemComponentElement, LightComponentElement, ListenerComponentElement, RenderComponentElement, RigidBodyComponentElement, ScreenComponentElement, ScrollbarComponentElement, ScrollViewComponentElement, ScriptComponentElement, ScriptElement, SoundComponentElement, SoundSlotElement, GSplatComponentElement, EntityBaseElement, MaterialElement, ModelElement, NodeElement, SceneElement, SkyElement, whenReady };
|
|
85
|
+
export { AsyncElement, ModuleElement, AppElement, EntityElement, AssetElement, AnimComponentElement, AnimClipElement, ButtonComponentElement, CameraComponentElement, CollisionComponentElement, ComponentElement, ElementComponentElement, JointComponentElement, LayoutChildComponentElement, LayoutGroupComponentElement, ParticleSystemComponentElement, LightComponentElement, ListenerComponentElement, RenderComponentElement, RigidBodyComponentElement, ScreenComponentElement, ScrollbarComponentElement, ScrollViewComponentElement, ScriptComponentElement, ScriptElement, SoundComponentElement, SoundSlotElement, GSplatComponentElement, EntityBaseElement, MaterialElement, ModelElement, NodeElement, SceneElement, SkyElement, whenReady };
|
|
82
86
|
export type { AsyncElementTagName } from './async-element.js';
|
|
83
87
|
export type { HierarchyMaterial, HierarchyNode } from './model.js';
|
|
84
88
|
export type { MaterialOverrides } from './node.js';
|