2024-12-09 12:14:50 +07:00

89 lines
4.7 KiB
HTML
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport"
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<link rel="stylesheet" href="libs/flatpickr/flatpickr.min.css">
<link rel="stylesheet" href="libs/flatpickr/theme.css">
<link rel="stylesheet" href="css/style.css">
<title>Библиотека UI компонентов</title>
</head>
<body>
<div class="grid">
<div class="input-fields">
<h1>Поля ввода</h1>
<h2>Строка</h2>
<form class="inputs">
<div class="c-labeled-input invalid">
<label for="username" class="c-label">Логин</label>
<input type="text" placeholder="Имя пользователя" class="c-input" id="username" autocomplete="username">
</div>
<div class="c-labeled-input">
<label for="password" class="c-label">Пароль</label>
<input type="password" placeholder="Пароль" class="c-input" id="password"
autocomplete="current-password">
<label for="password" class="c-label passwordVisibilityToggle">Показать пароль</label>
</div>
</form>
<h2>Число</h2>
<form class="inputs">
<div class="c-labeled-input">
<label for="num" class="c-label">Число</label>
<input type="number" placeholder="Введите число" class="c-input" id="num">
</div>
</form>
<h2>Дата</h2>
<form class="inputs">
<div class="c-labeled-input input-with-icon">
<label for="date-picker" class="c-label">Дата</label>
<input type="text" placeholder="Дата" class="c-input date-picker" id="date-picker" autocomplete="date">
<span class="calendar-icon">
<svg width="24" height="25" viewBox="0 0 24 25" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M19 4.5H5C3.89543 4.5 3 5.39543 3 6.5V20.5C3 21.6046 3.89543 22.5 5 22.5H19C20.1046 22.5 21 21.6046 21 20.5V6.5C21 5.39543 20.1046 4.5 19 4.5Z"
stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M16 2.5V6.5" stroke="currentColor" stroke-width="2" stroke-linecap="round"
stroke-linejoin="round"/>
<path d="M8 2.5V6.5" stroke="currentColor" stroke-width="2" stroke-linecap="round"
stroke-linejoin="round"/>
<path d="M3 10.5H21" stroke="currentColor" stroke-width="2" stroke-linecap="round"
stroke-linejoin="round"/>
</svg>
</span>
</div>
</form>
</div>
<div class="buttons">
<h1>Кнопки & ссылки</h1>
<div class="btns">
<button type="button" class="c-btn c-primary">Войти</button>
<button type="button">Выход</button>
<button type="button">Администрирование</button>
<button type="button">Аварийная ситуация</button>
<button type="button">Копировать(с иконкой слева)</button>
<button type="button">Добавить (c иконкой справа)</button>
</div>
</div>
</div>
<script src="libs/flatpickr/flatpickr.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/flatpickr/dist/l10n/ru.js"></script>
<script src="js/script.js"></script>
<script src="js/showPassword.js"></script>
</body>
</html>
<script>
const fp = flatpickr(".date-picker", {
dateFormat: "d.m.Y", // Формат даты
locale: "ru", // Локализация на русский
monthSelectorType: "dropdown", // Использование выпадающих списков для смены месяца
yearSelectorType: "select", // Использование выпадающего списка для выбора года
disableMobile: true
});
</script>
<!--<svg version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' viewBox='0 0 17 17'><g></g><path d='M5.207 8.471l7.146 7.147-0.707 0.707-7.853-7.854 7.854-7.853 0.707 0.707-7.147 7.146z' /></svg>-->
<!--<svg version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' viewBox='0 0 17 17'><g></g><path d='M13.207 8.472l-7.854 7.854-0.707-0.707 7.146-7.146-7.146-7.148 0.707-0.707 7.854 7.854z' /></svg>-->