1
0
Fork 0
mirror of https://github.com/jellyfin/jellyfin-web synced 2025-03-30 19:56:21 +00:00

update components

This commit is contained in:
Luke Pulverenti 2016-03-28 13:41:48 -04:00
parent 4a4c20e7c6
commit ee03ef4f51
27 changed files with 1767 additions and 21 deletions

View file

@ -1,6 +1,6 @@
{
"name": "iron-demo-helpers",
"version": "1.1.1",
"version": "1.2.0",
"description": "Utility classes to make building demo pages easier",
"authors": [
"The Polymer Authors"
@ -10,7 +10,10 @@
"polymer",
"demo"
],
"main": "demo-snippet.html",
"main": [
"demo-snippet.html",
"url-bar.html"
],
"private": true,
"repository": {
"type": "git",
@ -25,7 +28,8 @@
"paper-icon-button": "PolymerElements/paper-icon-button#^1.0.0",
"paper-styles": "PolymerElements/paper-styles#^1.0.0",
"marked-element": "polymerelements/marked-element#^1.0.0",
"prism-element": "PolymerElements/prism-element#^1.0.0"
"prism-element": "PolymerElements/prism-element#^1.0.0",
"iron-location": "PolymerElements/iron-location#^0.8.0"
},
"devDependencies": {
"webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0",
@ -37,11 +41,11 @@
"paper-styles": "PolymerElements/paper-styles#^1.1.0",
"paper-checkbox": "PolymerElements/paper-checkbox#^1.0.0"
},
"_release": "1.1.1",
"_release": "1.2.0",
"_resolution": {
"type": "version",
"tag": "v1.1.1",
"commit": "49584de566eae4f6c31cd1078ce0407b53c601eb"
"tag": "v1.2.0",
"commit": "b5385d0e1c6645560967dee564a43e66dfdf1993"
},
"_source": "git://github.com/polymerelements/iron-demo-helpers.git",
"_target": "^1.0.0",

View file

@ -0,0 +1,33 @@
<!-- Instructions: https://github.com/PolymerElements/iron-demo-helpers/CONTRIBUTING.md#filing-issues -->
### Description
<!-- Example: The `paper-foo` element causes the page to turn pink when clicked. -->
### Expected outcome
<!-- Example: The page stays the same color. -->
### Actual outcome
<!-- Example: The page turns pink. -->
### Live Demo
<!-- Example: https://jsbin.com/cagaye/edit?html,output -->
### Steps to reproduce
<!-- Example
1. Put a `paper-foo` element in the page.
2. Open the page in a web browser.
3. Click the `paper-foo` element.
-->
### Browsers Affected
<!-- Check all that apply -->
- [ ] Chrome
- [ ] Firefox
- [ ] Safari 9
- [ ] Safari 8
- [ ] Safari 7
- [ ] Edge
- [ ] IE 11
- [ ] IE 10

View file

@ -1,6 +1,6 @@
{
"name": "iron-demo-helpers",
"version": "1.1.1",
"version": "1.2.0",
"description": "Utility classes to make building demo pages easier",
"authors": [
"The Polymer Authors"
@ -10,7 +10,7 @@
"polymer",
"demo"
],
"main": "demo-snippet.html",
"main": ["demo-snippet.html", "url-bar.html"],
"private": true,
"repository": {
"type": "git",
@ -25,7 +25,8 @@
"paper-icon-button": "PolymerElements/paper-icon-button#^1.0.0",
"paper-styles": "PolymerElements/paper-styles#^1.0.0",
"marked-element": "polymerelements/marked-element#^1.0.0",
"prism-element": "PolymerElements/prism-element#^1.0.0"
"prism-element": "PolymerElements/prism-element#^1.0.0",
"iron-location": "PolymerElements/iron-location#^0.8.0"
},
"devDependencies": {
"webcomponentsjs": "webcomponents/webcomponentsjs#^0.7.0",

View file

@ -0,0 +1,47 @@
<!doctype html>
<!--
@license
Copyright (c) 2015 The Polymer Project Authors. All rights reserved.
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
Code distributed by Google as part of the polymer project is also
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
-->
<html lang="en">
<head>
<title>url-bar demo</title>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1, user-scalable=yes">
<script src="../../webcomponentsjs/webcomponents-lite.js"></script>
<link rel="import" href="../url-bar.html">
<link rel="import" href="../demo-pages-shared-styles.html">
<style is="custom-style" include="demo-pages-shared-styles">
iframe {
width: 100%;
}
</style>
</head>
<body unresolved>
<url-bar></url-bar>
<div id='message'></div>
<script>
var message;
if (window.top !== window) {
message = 'URL Bar should appear above this text';
} else {
message = 'No URL Bar above this text. iframe below this text with URL bar.';
var iframe = document.createElement('iframe');
iframe.setAttribute('src', window.location.href);
document.body.appendChild(iframe);
}
document.querySelector('#message').innerText = message;
</script>
</body>
</html>

View file

@ -22,7 +22,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
</head>
<body>
<iron-component-page></iron-component-page>
<iron-component-page src="demo-snippet.html"></iron-component-page>
</body>
</html>

View file

@ -0,0 +1,71 @@
<link rel="import" href="../polymer/polymer.html">
<link rel="import" href="../iron-location/iron-location.html">
<link rel="import" href="../iron-flex-layout/iron-flex-layout-classes.html">
<!--
`url-bar` is a helper element that displays a simple read-only URL bar if
and only if the page is in an iframe. In this way we can demo elements that
deal with the URL in our iframe-based demo environments.
If the page is not in an iframe, the url-bar element is not displayed.
@element url-bar
@demo demo/url-bar.html
-->
<dom-module id='url-bar'>
<template>
<style include="iron-flex">
:host {
margin: 0px;
padding: 15px 35px;
border-bottom: 2px solid gray;
height: 1em;
overflow: hidden;
display: none;
}
:host[in-iframe] {
/* This element only wants to be displayed if it's in an iframe. */
display: block;
}
label {
display: inline-block;
padding-right: 25px;
}
span {
font-family: monospace;
white-space: pre;
}
</style>
<iron-location path="{{path}}" query="{{query}}" hash="{{hash}}">
</iron-location>
<div class="layout horizontal">
<label>URL</label><span>{{url}}</span>
</div>
</template>
<script>
Polymer({
is: 'url-bar',
properties: {
url: {
computed: '__computeUrl(path, query, hash)'
},
inIframe: {
value: function() {
return window.top !== window;
},
reflectToAttribute: true
}
},
__computeUrl: function(path, query, hash) {
var url = path;
if (query) {
url += '?' + query;
}
if (hash) {
url += '#' + hash;
}
return url;
}
})
</script>
</dom-module>