Skip to content

Instantly share code, notes, and snippets.

View kcmr's full-sized avatar

Kus Cámara kcmr

View GitHub Profile

Falso select y toggle con input:checked

Sólo se usa javascript para cambiar el texto del select al seleccionar una opción.

A Pen by kcmr on CodePen.

License.

@kcmr
kcmr / Graph Bar with flex-basis transition.markdown
Created December 13, 2015 01:39
Graph Bar with flex-basis transition
@kcmr
kcmr / gulpfile.js
Last active February 12, 2016 01:11
Gulpfile template: compile scss + autoprefixer + browserSync reload
var gulp = require('gulp');
var sass = require('gulp-sass');
var browserSync = require('browser-sync');
var autoprefixer = require('gulp-autoprefixer');
gulp.task('sass', function() {
return gulp.src('scss/**/*.scss')
.pipe(sass())
.pipe(autoprefixer({
browsers: ['last 2 versions']
@kcmr
kcmr / WIP FlIP animations.markdown
Created May 25, 2016 23:22
WIP FlIP animations
@kcmr
kcmr / gulpfile.js
Last active July 17, 2017 22:26
PSK 2 Custom Build with livereload and autoprefixer for elements
'use strict';
const requireDir = require('require-dir');
const tasks = requireDir('./tasks');
@kcmr
kcmr / browsersync.conf.js
Created August 6, 2017 00:08
Browser Sync for a Polymer Web Component
const bs = require('browser-sync').create();
const componentPath = `/components/${__dirname.split('/').pop()}`;
bs.init({
files: [ '**/*.{html,js,css}' ],
open: false,
ghostMode: false,
startPath: `${componentPath}/demo/index.html`,
serveStatic: [{
route: componentPath,
@kcmr
kcmr / reboot.scss
Created October 30, 2017 21:43
reboot
// stylelint-disable at-rule-no-vendor-prefix, declaration-no-important, selector-no-qualifying-type, property-no-vendor-prefix
// Reboot
//
// Normalization of HTML elements, manually forked from Normalize.css to remove
// styles targeting irrelevant browsers while applying new styles.
//
// Normalize is licensed MIT. https://github.com/necolas/normalize.css
@kcmr
kcmr / logutils.js
Created November 25, 2017 21:21
Log utils
(function() {
'use strict';
function clearStyleWarnings(fn) {
return function(first, ...rest) {
if (!first.match('Could not find style data')) {
fn.call(this, first, ...rest);
}
}
}
@kcmr
kcmr / index.html
Created December 27, 2017 16:26
Example of a two-way binding that has no effect on the host property // source https://jsbin.com/doqedej
<!doctype html>
<html>
<head>
<meta name="description" content="Example of a two-way binding that has no effect on the host property">
<base href="https://polygit.org/polymer+:master/webcomponents+:master/shadycss+webcomponents+:master/components/">
<script src="webcomponentsjs/webcomponents-lite.js"></script>
<link rel="import" href="polymer/polymer.html">
<link rel="import" href="paper-toast/paper-toast.html">
</head>
<body>
@kcmr
kcmr / one-way-binding.html
Last active December 27, 2017 17:32
one-way data binding in Polymer
<dom-module id="my-component">
<template>
<paper-toast text="[[greeting]]"></paper-toast>
</template>
<script>
Polymer({
is: 'my-component',
properties: {