2023-07-23 13:48:09 +03:00
|
|
|
<!DOCTYPE html>
|
|
|
|
<html>
|
|
|
|
<head>
|
|
|
|
<meta charset="utf-8" />
|
|
|
|
<title>
|
|
|
|
“The API” book by Sergey Konstantinov. Examples to the “Decomposing
|
|
|
|
UI Components” chapter.
|
|
|
|
</title>
|
|
|
|
<link rel="stylesheet" type="text/css" href="../fonts.css" />
|
2023-07-30 15:25:21 +03:00
|
|
|
<link rel="icon" type="image/png" href="../../assets/favicon.png" />
|
|
|
|
<script
|
|
|
|
type="text/javascript"
|
|
|
|
src="../../assets/monaco-editor/dev/vs/loader.js"
|
|
|
|
></script>
|
|
|
|
<script type="text/javascript" src="./index.js"></script>
|
2023-07-23 13:48:09 +03:00
|
|
|
<style>
|
2023-07-30 15:25:21 +03:00
|
|
|
body {
|
|
|
|
padding: 5px;
|
2023-07-23 13:48:09 +03:00
|
|
|
}
|
2023-07-30 15:25:21 +03:00
|
|
|
|
|
|
|
ul#example-list {
|
|
|
|
list-style-type: none;
|
2023-07-23 13:48:09 +03:00
|
|
|
margin: 0;
|
2023-07-30 15:25:21 +03:00
|
|
|
padding: 0 0 5px 0;
|
|
|
|
}
|
|
|
|
ul#example-list > li {
|
|
|
|
margin: 2px 5px;
|
|
|
|
padding: 3px;
|
|
|
|
border: 2px solid rgba(128, 128, 128, 0.3);
|
|
|
|
display: inline-block;
|
|
|
|
}
|
|
|
|
|
|
|
|
ul#example-list > li > a {
|
|
|
|
color: inherit;
|
|
|
|
}
|
|
|
|
|
|
|
|
ul#example-list > li.selected {
|
|
|
|
border: 2px solid black;
|
2023-07-23 13:48:09 +03:00
|
|
|
}
|
|
|
|
|
2023-07-30 15:25:21 +03:00
|
|
|
#examples {
|
|
|
|
min-width: 400px;
|
|
|
|
}
|
|
|
|
|
|
|
|
#examples #editor {
|
|
|
|
min-height: 500px;
|
|
|
|
min-width: 400px;
|
|
|
|
width: calc(100% - 400px);
|
|
|
|
float: left;
|
|
|
|
}
|
|
|
|
|
|
|
|
#live-example {
|
|
|
|
min-width: 390px;
|
|
|
|
float: left;
|
|
|
|
}
|
|
|
|
|
|
|
|
#live-example iframe {
|
|
|
|
border: none;
|
|
|
|
margin: 0;
|
|
|
|
padding: 0;
|
|
|
|
width: 390px;
|
|
|
|
height: 500px;
|
|
|
|
overflow: hidden;
|
|
|
|
}
|
|
|
|
</style>
|
|
|
|
<script src="sandbox.js"></script>
|
2023-07-23 13:48:09 +03:00
|
|
|
</head>
|
|
|
|
<body>
|
|
|
|
<h1>
|
|
|
|
Examples of Overriding Different Aspects of a Decomposed UI
|
|
|
|
Component
|
|
|
|
</h1>
|
2023-07-30 15:25:21 +03:00
|
|
|
<div id="playground">
|
|
|
|
<div id="live-example">
|
|
|
|
<div>Live example <button id="refresh">Refresh</button></div>
|
|
|
|
<hr />
|
|
|
|
</div>
|
|
|
|
<div id="examples">
|
|
|
|
<ul id="example-list">
|
|
|
|
<li id="example-01">
|
|
|
|
<a href="javascript:showExample('01')"
|
|
|
|
>Example #1: A regular <code>SearchBox</code></a
|
|
|
|
>
|
|
|
|
</li>
|
|
|
|
<li id="example-02">
|
|
|
|
<a href="javascript:showExample('02')"
|
|
|
|
>Example #2: A <code>SearchBox</code> with a custom
|
|
|
|
icon</a
|
|
|
|
>
|
|
|
|
</li>
|
|
|
|
<li id="example-03">
|
|
|
|
<a href="javascript:showExample('03')"
|
|
|
|
>Example #3: A <code>SearchBox</code> with a map</a
|
|
|
|
>
|
|
|
|
</li>
|
|
|
|
<li id="example-04">
|
|
|
|
<a href="javascript:showExample('04')"
|
|
|
|
>Example #4: A <code>SearchBox</code> with in-place
|
|
|
|
actions</a
|
|
|
|
>
|
|
|
|
</li>
|
|
|
|
</ul>
|
|
|
|
<div id="editor"></div>
|
|
|
|
</div>
|
|
|
|
</div>
|
2023-07-23 13:48:09 +03:00
|
|
|
</body>
|
|
|
|
</html>
|