mirror of
https://github.com/cocos/cocos4.git
synced 2026-12-05 19:12:40 +08:00
29 lines
788 B
JavaScript
29 lines
788 B
JavaScript
const { template, $, update } = require('./base');
|
|
const MARGIN = '4PX';
|
|
|
|
exports.template = template;
|
|
exports.$ = $;
|
|
exports.update = update;
|
|
|
|
exports.ready = function() {
|
|
const $prop = document.createElement('ui-prop');
|
|
this.$.componentContainer.before($prop);
|
|
|
|
const $label = document.createElement('ui-label');
|
|
$label.setAttribute('slot', 'label');
|
|
$label.value = 'Generate';
|
|
$prop.appendChild($label);
|
|
|
|
const $button = document.createElement('ui-button');
|
|
$button.setAttribute('slot', 'content');
|
|
$button.setAttribute('class', 'blue');
|
|
$button.innerText = 'Generate';
|
|
$prop.appendChild($button);
|
|
|
|
$button.addEventListener('confirm', async () => {
|
|
// Call the bakeCubemap function in the Reflection Probe component
|
|
});
|
|
};
|
|
|
|
|