| 123456789101112131415161718192021222324252627282930 |
- import { is_string } from "./functions.js";
- class logo {
- #name;
- constructor(name) {
- if (!is_string(name)) {
- throw "Name must be an string.";
- }
- this.#name = name;
- }
- get name() {
- return this.#name;
- }
- get ui() {
- const container = document.createElement("div");
- container.className = "logo";
- const name = document.createElement("span");
- name.innerText = this.name;
-
- container.appendChild(name);
- return container;
- }
- }
- export { logo };
|