Skip to content

Instantly share code, notes, and snippets.

View powerbot15's full-sized avatar

Oleh Kastornov powerbot15

  • Master of Code
  • Ukraine
View GitHub Profile
@powerbot15
powerbot15 / data.js
Last active December 8, 2020 10:17
Images data
[
{
id: 'YhWRSEdBXUE',
description: null,
urls: {
raw: 'https://images.unsplash.com/photo-1601758228041-f3b2795255f1?ixid=MXwxODg5MjR8MXwxfGFsbHwxfHx8fHx8Mnw&ixlib=rb-1.2.1',
full: 'https://images.unsplash.com/photo-1601758228041-f3b2795255f1?crop=entropy&cs=srgb&fm=jpg&ixid=MXwxODg5MjR8MXwxfGFsbHwxfHx8fHx8Mnw&ixlib=rb-1.2.1&q=85',
regular: 'https://images.unsplash.com/photo-1601758228041-f3b2795255f1?crop=entropy&cs=tinysrgb&fit=max&fm=jpg&ixid=MXwxODg5MjR8MXwxfGFsbHwxfHx8fHx8Mnw&ixlib=rb-1.2.1&q=80&w=1080',
small: 'https://images.unsplash.com/photo-1601758228041-f3b2795255f1?crop=entropy&cs=tinysrgb&fit=max&fm=jpg&ixid=MXwxODg5MjR8MXwxfGFsbHwxfHx8fHx8Mnw&ixlib=rb-1.2.1&q=80&w=400',
thumb: 'https://images.unsplash.com/photo-1601758228041-f3b2795255f1?crop=entropy&cs=tinysrgb&fit=max&fm=jpg&ixid=MXwxODg5MjR8MXwxfGFsbHwxfHx8fHx8Mnw&ixlib=rb-1.2.1&q=80&w=200'
@powerbot15
powerbot15 / readme.md
Last active November 13, 2019 17:38
Modules Homework

Сделать новое приложение и засетапить webpack. https://webpack.js.org/guides/getting-started/#basic-setup Создать простую html страничку с формой, содержащей поля и кнопку сабмит.

Поля формы c необходимыми проверками:

First Name(min length 2, max length 20, required), 
Last Name(min length 2, max length 20, required),
Email(valid email, required),
Phone(+38(000)000-00-00, required)
Age(number, range 18-120, optional) //check range only if present

#Задание слайдер(карусель)

Написать циклический слайдер для элементов списка. Шаблон верстки для слайдера

  <div data-slider>
    <button type="button">prev</button>
    <ul>
        <li><a href="#">Link 1</a></li>
 <a href="#">Link 2</a>
@powerbot15
powerbot15 / readme.md
Last active November 11, 2016 12:38
HW

Домашняя работа по лекции №1

  1. Создать пустой массив

  2. Добавить в него 100 целых чисел от 1 до 100 с помощью метода Math.random()

  3. Написать функцию поиска и вывода в консоль максимального или минимального элемента. Функция должна называться findMinMax , принимать в параметрах массив для поиска и строку, определяющую действие функции. Функция должна возвратить найденный элемент Пример использования функции

$('document').on('submit', 'form', submitMany);
function submitMany(){
var form = $(this);
if(validateAction(form.prop('action'))){
alert('!!!');
}
<!DOCTYPE html>
<html>
<head lang="en">
<meta charset="UTF-8">
<title>Test</title>
<style>
h1{
color:darkblue;
background-color: aquamarine;
}
(function($){
$.prototype.fallingText = function(intervalBetweenFalls, fallDuration){
var $spansForEffect,
spansIndexes,
currentIndex = 0,
counter = 0;
setArrayShuffleMethod();
@powerbot15
powerbot15 / gist:7833751
Last active December 30, 2015 13:09
coffee script
sourceImage = undefined
convertedImage = undefined
context = undefined
window.onload = ->
sourceImage = document.getElementById 'source-image'
convertedImage = document.getElementById 'converted-image'
context = convertedImage.getContext '2d'
convertedImage.width = sourceImage.width
@powerbot15
powerbot15 / gist:7440871
Last active December 28, 2015 04:18
lesson6 homework
;(function(){
var limited = function(delay,functionToFreeze){
if(typeof delay === 'function'){
functionToFreeze = delay;
delay = 20;
}
var notExecutingNow=true,
savedArguments,
self,