async function onclick(e) {
		const $target = e.target;
		const { key } = e.target.dataset;

		const item = items.find((item) => item.key === key);
		if (!item) return;

		const {
			select: options,
			prompt: promptText,
			color: selectColor,
			checkbox,
			file,
			folder,
			link,
		} = item;
		const { text, value, valueText } = item;
		const { promptType, promptOptions } = item;

		const $valueText = $target.get(".value");
		const $checkbox = $target.get(".input-checkbox");
		let res;

		try {
			if (options) {
				res = await select(text, options, {
					default: value,
				});
			} else if (checkbox !== undefined) {
				$checkbox.toggle();
				res = $checkbox.checked;
			} else if (promptText) {
				res = await prompt(promptText, value, promptType, promptOptions);
				if (res === null) return;
			} else if (file || folder) {
				const mode = file ? "file" : "folder";
				const { url } = await FileBrowser(mode);
				res = url;
			} else if (selectColor) {
				res = await colorPicker(value);
			} else if (link) {
				system.openInBrowser(link);
				return;
			}
		} catch (error) {
			window.log("error", error);
		}

		item.value = res;
		setValueText($valueText, res, valueText?.bind(item));
		setColor($target, res);
		callback.call($target, key, item.value);
	}
Click handler for $list
@this {HTMLElement}
@param {MouseEvent} e