This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export const patterns = [{ | |
name:"Date in format dd/mm/yyyy", | |
regex:/^(0?[1-9]|[12][0-9]|3[01])([ /\-])(0?[1-9]|1[012])\2([0-9][0-9][0-9][0-9])(([ -])([0-1]?[0-9]|2[0-3]):[0-5]?[0-9]:[0-5]?[0-9])?$/, | |
description:"Will match dates with dashes, slashes or with spaces (e.g. dd-mm-yyyy dd/mm/yyyy dd mm yyyy), and optional time separated by a space or a dash (e.g. dd-mm-yyyy-hh:mm:ss or dd/mm/yyyy hh:mm:ss).", | |
tags:"date,time" | |
}, | |
{ | |
name:"Time in 24-hour format", | |
regex:/^([01]?[0-9]|2[0-3]):[0-5][0-9]$/, | |
description: "Match times in 24 hour format", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export const URL_PATTERNS = [ | |
{ prefix: 'tel', re: /(\+7)[\s\-()0-9]{10,}/ }, | |
{ prefix: 'mailto', re: /^.+@.+$/ } | |
] | |
/** | |
* @param {Promise[]} promises | |
* @returns Promise | |
*/ | |
export function promiseQueue (promises = []) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<template> | |
<div class="checkbox" @click="isChecked = !isChecked"> | |
<input v-model="isChecked" type="checkbox" style="display: none" > | |
<label> | |
<span> | |
<svg width="12px" height="10px" viewbox="0 0 12 10"> | |
<polyline points="1.5 6 4.5 9 10.5 1"></polyline> | |
</svg> | |
</span> | |
<span>{{ label }}</span> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<template> | |
<svg class="donut"> | |
<transition-group tag="g" name="circle" appear> | |
<circle | |
ref="circle" | |
v-for="(circle, i) in circles" :key="i" | |
:r="radius" | |
:stroke="colors[i]" | |
:stroke-dasharray="circle.dashArray" | |
:stroke-dashoffset="circle.dashOffset" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$domain = "example.com"; | |
// Подключение к БД | |
$host = ""; | |
$user = ""; | |
$pass = ""; | |
$db = ""; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<IfModule mod_expires.c> | |
ExpiresActive On | |
ExpiresDefault "access 7 days" | |
ExpiresByType application/javascript "access plus 1 year" | |
ExpiresByType text/javascript "access plus 1 year" | |
ExpiresByType text/css "access plus 1 year" | |
ExpiresByType text/html "access plus 7 day" | |
ExpiresByType text/x-javascript "access 1 year" | |
ExpiresByType image/gif "access plus 1 year" | |
ExpiresByType image/jpeg "access plus 1 year" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
placeholder(color) | |
&::-webkit-input-placeholder | |
color color | |
&:-moz-placeholder | |
color color | |
&::-moz-placeholder | |
color color | |
&:-ms-input-placeholder | |
color color |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Styles for autofilled inputs, textareas, selects | |
input:-webkit-autofill { | |
-webkit-text-fill-color black | |
-webkit-box-shadow 0 0 0px 100px white inset | |
} | |
// Подсветка элемента при тапе на мобилах | |
div { | |
-webkit-tap-highlight-color: transparent; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* 1. Установить yaml-loader | |
* 2. Создать файл ~/locales/[name].yaml | |
* | |
* Содержимое файла | |
* About: | |
* ru: О нас | |
*/ | |
import Vue from 'vue' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
html { | |
line-height: 1.2; | |
text-decoration-skip: ink; | |
-webkit-font-smoothing: antialiased; | |
-moz-osx-font-smoothing: grayscale; | |
} | |
body, | |
p, | |
figure, |
OlderNewer