Skip to content

Instantly share code, notes, and snippets.

View jarrodek's full-sized avatar

Paweł Uchida-Psztyć jarrodek

View GitHub Profile
@jarrodek
jarrodek / designer.html
Last active August 29, 2015 14:15
designer
<link rel="import" href="../core-drawer-panel/core-drawer-panel.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">
<polymer-element name="my-element">
<template>
<style>
#core_header_panel {
@jarrodek
jarrodek / designer.html
Last active August 29, 2015 14:17
designer
<link rel="import" href="../core-drawer-panel/core-drawer-panel.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">
<polymer-element name="my-element">
<template>
<style>
:host {
@jarrodek
jarrodek / headers-test.js
Created April 20, 2016 11:48
Headers object transforming headers cases
var headers = new Headers();
headers.append('Authorization', 'Basic abc');
headers.append('Connection', 'close');
var message = '';
for(var header of headers) {
message += header[0] + ': ' + header[1] + '\n';
}
var testConstruct = 'Authorization: Basic abc\n';
@jarrodek
jarrodek / polymer-import-location.js
Created March 9, 2017 11:28
A script that recognizes Polymer element's URL and parses it to read location of assets like web workers to import during runtime.
var importLocation = '';
(function() {
var url;
if (window.currentImport && window.currentImport.URL) {
url = window.currentImport.URL;
if (window.currentImport._URL) {
url = window.currentImport._URL;
}
} else if (window.currentImport._URL) {
url = window.currentImport._URL;
@jarrodek
jarrodek / atom-beautify-debug-output.md
Last active May 26, 2017 16:32
atom beautify debug output
@jarrodek
jarrodek / affirmation
Created May 30, 2017 13:42
MuleSoft Contributor Agreement Acceptance by Pawel Psztyc
I, Pawel Psztyc, have read and do accept the MuleSoft Contributor Agreement
at http://www.mulesoft.org/legal/contributor-agreement.html
Accepted on Tue May 30 2017 14:42:45 GMT+0100 (BST)
@jarrodek
jarrodek / api-console-styles.html
Created August 8, 2017 17:00
API console styles example
<style is="custom-style">
:root {
--arc-color-primary: pink; /* overrides: --primary-color: var(--arc-color-primary, #00a2df); */
--arc-font-family: Verdana; /* overrides: --arc-font-common-base and therefore all fonts definitions */
--arc-request-panel: {
/* Applied to whole reqiuest panel, after applying default styling that can be changed here */
margin-bottom: 120px;
}
@jarrodek
jarrodek / apic-build-fragments.js
Created June 18, 2018 18:53
An example of building the API console with api-console-builder
const builder = require('api-console-builder');
builder({
tagName: '5.0.0-preview',
embedded: true,
themeFile: './my-theme.html',
destination: 'console-bundle'
})
.then(() => console.log('Build complete <3'))
.catch((cause) => console.log('Build error <\\3', cause.message));
const builder = require('api-console-builder');
builder({
dest: 'build',
// noOptimization: true,
embedded: true,
verbose: true,
raml: 'api.raml'
})
.then(() => console.log('Build complete'))
@jarrodek
jarrodek / webcomponentsjs-error.html
Created December 27, 2018 11:58
A description of the issue for webcomponentsjs library
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, minimum-scale=1, initial-scale=1, user-scalable=yes">
<title>Issue reproduction</title>
<script src="../../webcomponentsjs/webcomponents-loader.js"></script>
<style>
html,
body {