mirror of
https://github.com/cocos/cocos4.git
synced 2026-11-20 23:52:40 +08:00
39 lines
1.0 KiB
HTML
39 lines
1.0 KiB
HTML
<html>
|
|
<head>
|
|
<meta charset="utf-8">
|
|
<link rel="import" href="editor-framework://test/page-utils/page-runner.html">
|
|
|
|
<dom-module id="test-focusable">
|
|
<template>
|
|
<div id="focus"
|
|
on-focus="_onFocus"
|
|
on-blur="_onBlur"
|
|
>Test Focusable</div>
|
|
</template>
|
|
<script>
|
|
var TestFocusable = Polymer({
|
|
is: 'test-focusable',
|
|
behaviors: [EditorUI.focusable],
|
|
ready: function () {
|
|
this._initFocusable(this.$.focus);
|
|
},
|
|
});
|
|
</script>
|
|
</dom-module>
|
|
</head>
|
|
<body>
|
|
<h1>Testing Behaviours</h1>
|
|
<div id="test-area"></div>
|
|
<script>
|
|
(function () {
|
|
var queries = Editor.argv;
|
|
var script = queries.scriptUrl;
|
|
if (!script) {
|
|
console.error('failed to get script to run');
|
|
return;
|
|
}
|
|
require(script);
|
|
})();
|
|
</script>
|
|
</body>
|
|
</html> |