Skip to content

Instantly share code, notes, and snippets.

View jrsalunga's full-sized avatar
💭
I may be slow to respond.

Jefferson Raga Salunga jrsalunga

💭
I may be slow to respond.
View GitHub Profile
@jrsalunga
jrsalunga / designer.html
Created October 24, 2014 13:27
designer
<link rel="import" href="../core-pages/core-pages.html">
<link rel="import" href="../core-icon-button/core-icon-button.html">
<link rel="import" href="../core-toolbar/core-toolbar.html">
<link rel="import" href="../core-header-panel/core-header-panel.html">
<link rel="import" href="../core-input/core-input.html">
<polymer-element name="my-element">
<template>
<style>
@jrsalunga
jrsalunga / designer.html
Last active August 29, 2015 14:07
designer
<link rel="import" href="../topeka-elements/theme.html">
<link rel="import" href="../topeka-elements/topeka-resources.html">
<link rel="import" href="../topeka-elements/topeka-app.html">
<polymer-element name="my-element">
<template>
<style>
:host {
position: absolute;
if(k.match(/id$/) && k.length > 2){ // eg: "userid" no "id"
var s = k.split('id')[0];
this.$el.find(".table-model #"+s+".search").val(this.model.get(k));
}
if(key.substr(key.length - 2) === 'id'){
$(".table-model").find('#'+key+' option[value='+data[key]+']').attr('selected', 'selected');