Initial commit
1
.gitignore
vendored
Normal file
@ -0,0 +1 @@
|
||||
/node_modules
|
6
.npmignore
Normal file
@ -0,0 +1,6 @@
|
||||
Gruntfile.js
|
||||
tasks
|
||||
node_modules
|
||||
test
|
||||
.travis.yml
|
||||
appveyor.yml
|
7
.travis.yml
Normal file
@ -0,0 +1,7 @@
|
||||
os:
|
||||
- linux
|
||||
language: node_js
|
||||
node_js:
|
||||
- '4'
|
||||
- '8'
|
||||
- '10'
|
157
Gruntfile.js
Normal file
@ -0,0 +1,157 @@
|
||||
// To use this file in WebStorm, right click on the file name in the Project Panel (normally left) and select "Open Grunt Console"
|
||||
|
||||
/** @namespace __dirname */
|
||||
/* jshint -W097 */// jshint strict:false
|
||||
/*jslint node: true */
|
||||
"use strict";
|
||||
|
||||
module.exports = function (grunt) {
|
||||
|
||||
var srcDir = __dirname + '/';
|
||||
var dstDir = srcDir + '.build/';
|
||||
var pkg = grunt.file.readJSON('package.json');
|
||||
var iopackage = grunt.file.readJSON('io-package.json');
|
||||
var version = (pkg && pkg.version) ? pkg.version : iopackage.common.version;
|
||||
|
||||
console.log(srcDir + 'widgets/' + pkg.name.substring('yunkong2.vis-'.length) + '/js/' + pkg.name.substring('yunkong2.vis-'.length) + '.js');
|
||||
// Project configuration.
|
||||
grunt.initConfig({
|
||||
pkg: pkg,
|
||||
clean: {
|
||||
all: ['tmp/*.json', 'tmp/*.zip', 'tmp/*.jpg', 'tmp/*.jpeg', 'tmp/*.png',
|
||||
dstDir + '*.json', dstDir + '*.zip', dstDir + '*.jpg', dstDir + '*.jpeg', dstDir + '*.png']
|
||||
},
|
||||
replace: {
|
||||
core: {
|
||||
options: {
|
||||
patterns: [
|
||||
{
|
||||
match: /version: *"[\.0-9]*"/g,
|
||||
replacement: 'version: "' + version + '"'
|
||||
},
|
||||
{
|
||||
match: /"version":\s*"[\.0-9]*",/g,
|
||||
replacement: '"version": "' + version + '",'
|
||||
},
|
||||
{
|
||||
match: /version: *"[\.0-9]*",/g,
|
||||
replacement: 'version: "' + version + '",'
|
||||
}
|
||||
]
|
||||
},
|
||||
files: [
|
||||
{
|
||||
expand: true,
|
||||
flatten: true,
|
||||
src: [
|
||||
srcDir + 'package.json',
|
||||
srcDir + 'io-package.json'
|
||||
],
|
||||
dest: srcDir
|
||||
},
|
||||
{
|
||||
expand: true,
|
||||
flatten: true,
|
||||
src: [
|
||||
srcDir + 'widgets/' + pkg.name.substring('yunkong2.vis-'.length) + '.html'
|
||||
],
|
||||
dest: srcDir + 'widgets'
|
||||
},
|
||||
{
|
||||
expand: true,
|
||||
flatten: true,
|
||||
src: [
|
||||
srcDir + 'widgets/' + pkg.name.substring('yunkong2.vis-'.length) + '/js/' + pkg.name.substring('yunkong2.vis-'.length) + '.js'
|
||||
],
|
||||
dest: srcDir + 'widgets/' + pkg.name.substring('yunkong2.vis-'.length) + '/js/'
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
// Javascript code styler
|
||||
jscs: require(__dirname + '/tasks/jscs.js'),
|
||||
// Lint
|
||||
jshint: require(__dirname + '/tasks/jshint.js'),
|
||||
http: {
|
||||
get_hjscs: {
|
||||
options: {
|
||||
url: 'https://raw.githubusercontent.com/yunkong2/yunkong2.js-controller/master/tasks/jscs.js'
|
||||
},
|
||||
dest: 'tasks/jscs.js'
|
||||
},
|
||||
get_jshint: {
|
||||
options: {
|
||||
url: 'https://raw.githubusercontent.com/yunkong2/yunkong2.js-controller/master/tasks/jshint.js'
|
||||
},
|
||||
dest: 'tasks/jshint.js'
|
||||
},/*
|
||||
get_gruntfile: {
|
||||
options: {
|
||||
url: 'https://raw.githubusercontent.com/yunkong2/yunkong2.build/master/adapters/Gruntfile.js'
|
||||
},
|
||||
dest: 'Gruntfile.js'
|
||||
},
|
||||
get_utilsfile: {
|
||||
options: {
|
||||
url: 'https://raw.githubusercontent.com/yunkong2/yunkong2.build/master/adapters/utils.js'
|
||||
},
|
||||
dest: 'lib/utils.js'
|
||||
},*/
|
||||
get_jscsRules: {
|
||||
options: {
|
||||
url: 'https://raw.githubusercontent.com/yunkong2/yunkong2.js-controller/master/tasks/jscsRules.js'
|
||||
},
|
||||
dest: 'tasks/jscsRules.js'
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
grunt.registerTask('updateReadme', function () {
|
||||
var readme = grunt.file.read('README.md');
|
||||
var pos = readme.indexOf('## Changelog\r\n');
|
||||
if (pos != -1) {
|
||||
var readmeStart = readme.substring(0, pos + '## Changelog\r\n'.length);
|
||||
var readmeEnd = readme.substring(pos + '## Changelog\r\n'.length);
|
||||
|
||||
if (readme.indexOf(version) == -1) {
|
||||
var timestamp = new Date();
|
||||
var date = timestamp.getFullYear() + '-' +
|
||||
("0" + (timestamp.getMonth() + 1).toString(10)).slice(-2) + '-' +
|
||||
("0" + (timestamp.getDate()).toString(10)).slice(-2);
|
||||
|
||||
var news = "";
|
||||
if (iopackage.common.whatsNew) {
|
||||
for (var i = 0; i < iopackage.common.whatsNew.length; i++) {
|
||||
if (typeof iopackage.common.whatsNew[i] == 'string') {
|
||||
news += '* ' + iopackage.common.whatsNew[i] + '\r\n';
|
||||
} else {
|
||||
news += '* ' + iopackage.common.whatsNew[i].en + '\r\n';
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grunt.file.write('README.md', readmeStart + '### ' + version + ' (' + date + ')\r\n' + (news ? news + '\r\n\r\n' : '\r\n') + readmeEnd);
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
grunt.loadNpmTasks('grunt-replace');
|
||||
grunt.loadNpmTasks('grunt-contrib-jshint');
|
||||
grunt.loadNpmTasks('grunt-jscs');
|
||||
grunt.loadNpmTasks('grunt-http');
|
||||
|
||||
grunt.registerTask('default', [
|
||||
'http',
|
||||
'replace',
|
||||
'updateReadme',
|
||||
'jshint',
|
||||
'jscs'
|
||||
]);
|
||||
grunt.registerTask('prepublish', [
|
||||
'replace',
|
||||
'updateReadme'
|
||||
]);
|
||||
grunt.registerTask('p', [
|
||||
'prepublish'
|
||||
]);
|
||||
};
|
22
LICENSE
Normal file
@ -0,0 +1,22 @@
|
||||
The MIT License (MIT)
|
||||
|
||||
Copyright (c) 2015 Bluefox <dogafox@gmail.com>
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
||||
|
55
README.md
Normal file
@ -0,0 +1,55 @@
|
||||
![Logo](admin/timeandweather.png)
|
||||
yunkong2.vis-timeandweather
|
||||
============
|
||||
|
||||
[![NPM version](http://img.shields.io/npm/v/yunkong2.vis-timeandweather.svg)](https://www.npmjs.com/package/yunkong2.vis-timeandweather)
|
||||
[![Downloads](https://img.shields.io/npm/dm/yunkong2.vis-timeandweather.svg)](https://www.npmjs.com/package/yunkong2.vis-timeandweather)
|
||||
|
||||
[![NPM](https://nodei.co/npm/yunkong2.vis-timeandweather.png?downloads=true)](https://nodei.co/npm/yunkong2.vis-timeandweather/)
|
||||
|
||||
|
||||
timeandweather - Time and weather widgets for yunkong2.vis.
|
||||
|
||||
Used following packages:
|
||||
- **CoolClock** http://randomibis.com/coolclock/ by Simon Baird (MIT)
|
||||
https://github.com/simonbaird/CoolClock/
|
||||
- **jDigiClock** http://www.radoslavdimov.com/jquery-plugins/jquery-plugin-digiclock/ by Radoslav Dimov (MIT & GPL)
|
||||
- **zWeatherFeed** http://www.zazar.net/developers/jquery/zweatherfeed/ Zazar Ltd (MIT)
|
||||
- **Segment display** http://www.3quarks.com/en/SegmentDisplay (CC-3.0)
|
||||
- **flipclock** http://flipclockjs.com/ (MIT)
|
||||
https://github.com/objectivehtml/FlipClock
|
||||
|
||||
|
||||
![Example](img/widgets.png)
|
||||
|
||||
## Changelog
|
||||
### 1.1.7 (2017-01-05)
|
||||
- (bluefox) add update interval for weather
|
||||
|
||||
### 1.1.6 (2016-07-13)
|
||||
- (bluefox) support of vis APP
|
||||
|
||||
### 1.1.4 (2016-06-28)
|
||||
- (jens-maus) improved german translation of weather terms
|
||||
|
||||
### 1.1.3 (2016-06-23)
|
||||
- (bluefox) enable widgets for https too
|
||||
|
||||
### 1.1.2 (2016-06-02)
|
||||
- (bluefox) add weather custom widget
|
||||
|
||||
### 1.1.1 (2016-05-31)
|
||||
- (bluefox) fix the slide in htc weather
|
||||
|
||||
### 1.1.0 (2016-04-16)
|
||||
- (bluefox) add city name to display
|
||||
|
||||
### 0.1.0 (2016-02-10)
|
||||
- (bluefox) fix typo with Dienstag=>Februar
|
||||
|
||||
### 0.0.1 (2015-10-04)
|
||||
- (bluefox) initial checkin
|
||||
|
||||
## License
|
||||
Copyright (c) 2013-2016 bluefox https://github.com/GermanBluefox
|
||||
MIT
|
61
admin/index.html
Normal file
@ -0,0 +1,61 @@
|
||||
<html>
|
||||
|
||||
<!-- these 4 files always have to be included -->
|
||||
<link rel="stylesheet" type="text/css" href="../../lib/css/themes/jquery-ui/redmond/jquery-ui.min.css"/>
|
||||
<link rel="stylesheet" type="text/css" href="../../lib/css/jquery.multiselect-1.13.css"/>
|
||||
|
||||
<script type="text/javascript" src="../../lib/js/jquery-1.11.1.min.js"></script>
|
||||
<script type="text/javascript" src="../../socket.io/socket.io.js"></script>
|
||||
<script type="text/javascript" src="../../lib/js/jquery-ui-1.10.3.full.min.js"></script>
|
||||
|
||||
<!-- these two file always have to be included -->
|
||||
<link rel="stylesheet" type="text/css" href="../../css/adapter.css"/>
|
||||
<script type="text/javascript" src="../../js/translate.js"></script>
|
||||
<script type="text/javascript" src="../../js/adapter-settings.js"></script>
|
||||
|
||||
<style>
|
||||
.table_header {
|
||||
background-color: blue;
|
||||
color: white;
|
||||
}
|
||||
.ip {
|
||||
width: 150px;
|
||||
text-align: right;
|
||||
}
|
||||
</style>
|
||||
<!-- you have to define 2 functions in the global scope: -->
|
||||
<script type="text/javascript">
|
||||
systemDictionary = {
|
||||
"Fancyswitch Widgets settings": {
|
||||
"en": "Fancyswitch Widgets settings",
|
||||
"de": "Fancyswitch Widgets Einstellungen",
|
||||
"ru": "Настройки Fancyswitch Widgets"
|
||||
},
|
||||
"There is nothing to setup": {
|
||||
"en": "There is nothing to setup",
|
||||
"de": "Es gibt nichts einzustellen",
|
||||
"ru": "Нечего настраивать"
|
||||
},
|
||||
};
|
||||
|
||||
function load(settings, onChange) {
|
||||
if (!settings) return;
|
||||
|
||||
onChange(false);
|
||||
}
|
||||
|
||||
function save(callback) {
|
||||
callback(null);
|
||||
}
|
||||
</script>
|
||||
|
||||
<div id="adapter-container">
|
||||
|
||||
<table><tr>
|
||||
<td><img src="hqwidgets.png"></td>
|
||||
<td style="padding-top: 20px;padding-left: 10px"><h3 class="translate">Fancyswitch Widgets settings</h3></td>
|
||||
</tr></table>
|
||||
|
||||
<div class="translate">There is nothing to setup</h4>
|
||||
</div>
|
||||
</html>
|
BIN
admin/timeandweather.png
Normal file
After Width: | Height: | Size: 5.2 KiB |
BIN
img/widgets.png
Normal file
After Width: | Height: | Size: 400 KiB |
75
io-package.json
Normal file
@ -0,0 +1,75 @@
|
||||
{
|
||||
"common": {
|
||||
"name": "vis-timeandweather",
|
||||
"version": "1.1.7",
|
||||
"news": {
|
||||
"1.1.7": {
|
||||
"en": "add update interval for weather",
|
||||
"de": "Updateintervalle für Wetter hinzugefügt",
|
||||
"ru": "Добавлен интервал обновления для погоды"
|
||||
},
|
||||
"1.1.6": {
|
||||
"en": "support of vis APP",
|
||||
"de": "support of vis APP",
|
||||
"ru": "support of vis APP"
|
||||
},
|
||||
"1.1.4": {
|
||||
"en": "better translations",
|
||||
"de": "better translations",
|
||||
"ru": "better translations"
|
||||
},
|
||||
"1.1.3": {
|
||||
"en": "enable widgets for https too",
|
||||
"de": "enable widgets for https too",
|
||||
"ru": "enable widgets for https too"
|
||||
},
|
||||
"1.1.2": {
|
||||
"en": "add weather custom widget",
|
||||
"de": "add weather custom widget",
|
||||
"ru": "add weather custom widget"
|
||||
},
|
||||
"1.1.1": {
|
||||
"en": "fix the slide in htc weather",
|
||||
"de": "fix the slide in htc weather",
|
||||
"ru": "fix the slide in htc weather"
|
||||
}
|
||||
},
|
||||
"title": "yunkong2 Visualisation - time and weather Widgets",
|
||||
"desc": {
|
||||
"en": "Time and weather widgets for yunkong2.vis",
|
||||
"de": "Zeit und Wetter Widgets für yunkong2.vis",
|
||||
"ru": "Widgets времени и погоды для yunkong2.vis"
|
||||
},
|
||||
"platform": "Javascript/Node.js",
|
||||
"loglevel": "info",
|
||||
"icon": "timeandweather.png",
|
||||
"enabled": true,
|
||||
"mode": "once",
|
||||
"extIcon": "https://git.spacen.net/yunkong2/yunkong2.vis-timeandweather/raw/master/admin/timeandweather.png",
|
||||
"keywords": [
|
||||
"timeandweather",
|
||||
"vis",
|
||||
"GUI",
|
||||
"graphical",
|
||||
"scada"
|
||||
],
|
||||
"readme": "https://github.com/yunkong2/yunkong2.vis-timeandweather/blob/master/README.md",
|
||||
"authors": [
|
||||
"bluefox <dogafox@gmail.com>"
|
||||
],
|
||||
"localLink": "%web_protocol%://%ip%:%web_port%/vis/edit.html",
|
||||
"license": "MIT",
|
||||
"dependencies": [
|
||||
"vis"
|
||||
],
|
||||
"onlyWWW": true,
|
||||
"singleton": true,
|
||||
"type": "visualization-widgets",
|
||||
"noConfig": true,
|
||||
"restartAdapters": [
|
||||
"vis"
|
||||
]
|
||||
},
|
||||
"native": {},
|
||||
"instanceObjects": []
|
||||
}
|
49
package.json
Normal file
@ -0,0 +1,49 @@
|
||||
{
|
||||
"name": "yunkong2.vis-timeandweather",
|
||||
"description": "Time and weather widgets for yunkong2.vis",
|
||||
"version": "1.1.7",
|
||||
"author": {
|
||||
"name": "bluefox",
|
||||
"email": "dogafox@gmail.com"
|
||||
},
|
||||
"contributors": [
|
||||
"bluefox <dogafox@gmail.com>"
|
||||
],
|
||||
"homepage": "https://github.com/yunkong2/yunkong2.vis-timeandweather",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/yunkong2/yunkong2.vis-timeandweather"
|
||||
},
|
||||
"licenses": [
|
||||
{
|
||||
"type": "MIT",
|
||||
"url": "https://github.com/yunkong2/yunkong2.vis-timeandweather/blob/master/LICENSE"
|
||||
}
|
||||
],
|
||||
"keywords": [
|
||||
"yunkong2",
|
||||
"GUI",
|
||||
"DashUI",
|
||||
"web interface",
|
||||
"home automation",
|
||||
"SCADA",
|
||||
"timeandweather GUI"
|
||||
],
|
||||
"devDependencies": {
|
||||
"grunt": "^1.0.1",
|
||||
"grunt-replace": "^1.0.1",
|
||||
"grunt-contrib-jshint": "^1.1.0",
|
||||
"grunt-jscs": "^3.0.1",
|
||||
"grunt-http": "^2.2.0",
|
||||
"mocha": "^4.1.0",
|
||||
"chai": "^4.1.2"
|
||||
},
|
||||
"bugs": {
|
||||
"url": "https://github.com/yunkong2/yunkong2.vis-timeandweather/issues"
|
||||
},
|
||||
"main": "widgets/timeandweather.html",
|
||||
"scripts": {
|
||||
"test": "node node_modules/mocha/bin/mocha --exit"
|
||||
},
|
||||
"license": "MIT"
|
||||
}
|
17
tasks/jscs.js
Normal file
@ -0,0 +1,17 @@
|
||||
var srcDir = __dirname + "/../";
|
||||
|
||||
module.exports = {
|
||||
all: {
|
||||
src: [
|
||||
srcDir + "*.js",
|
||||
srcDir + "lib/*.js",
|
||||
srcDir + "adapter/example/*.js",
|
||||
srcDir + "tasks/**/*.js",
|
||||
srcDir + "www/**/*.js",
|
||||
'!' + srcDir + "www/lib/**/*.js",
|
||||
'!' + srcDir + 'node_modules/**/*.js',
|
||||
'!' + srcDir + 'adapter/*/node_modules/**/*.js'
|
||||
],
|
||||
options: require('./jscsRules.js')
|
||||
}
|
||||
};
|
36
tasks/jscsRules.js
Normal file
@ -0,0 +1,36 @@
|
||||
module.exports = {
|
||||
force: true,
|
||||
"requireCurlyBraces": ["else", "for", "while", "do", "try", "catch"], /*"if",*/
|
||||
"requireSpaceAfterKeywords": ["if", "else", "for", "while", "do", "switch", "return", "try", "catch"],
|
||||
"requireSpaceBeforeBlockStatements": true,
|
||||
"requireParenthesesAroundIIFE": true,
|
||||
"disallowSpacesInFunctionDeclaration": {"beforeOpeningRoundBrace": true},
|
||||
"disallowSpacesInNamedFunctionExpression": {"beforeOpeningRoundBrace": true},
|
||||
"requireSpacesInFunctionExpression": {"beforeOpeningCurlyBrace": true},
|
||||
"requireSpacesInAnonymousFunctionExpression": {"beforeOpeningRoundBrace": true, "beforeOpeningCurlyBrace": true},
|
||||
"requireSpacesInNamedFunctionExpression": {"beforeOpeningCurlyBrace": true},
|
||||
"requireSpacesInFunctionDeclaration": {"beforeOpeningCurlyBrace": true},
|
||||
"disallowMultipleVarDecl": true,
|
||||
"requireBlocksOnNewline": true,
|
||||
"disallowEmptyBlocks": true,
|
||||
"disallowSpacesInsideObjectBrackets": true,
|
||||
"disallowSpacesInsideArrayBrackets": true,
|
||||
"disallowSpaceAfterObjectKeys": true,
|
||||
"disallowSpacesInsideParentheses": true,
|
||||
"requireCommaBeforeLineBreak": true,
|
||||
//"requireAlignedObjectValues": "all",
|
||||
"requireOperatorBeforeLineBreak": ["?", "+", "-", "/", "*", "=", "==", "===", "!=", "!==", ">", ">=", "<", "<="],
|
||||
// "disallowLeftStickedOperators": ["?", "+", "/", "*", "=", "==", "===", "!=", "!==", ">", ">=", "<", "<="],
|
||||
// "requireRightStickedOperators": ["!"],
|
||||
// "requireSpaceAfterBinaryOperators": ["?", "+", "/", "*", ":", "=", "==", "===", "!=", "!==", ">", ">=", "<", "<="],
|
||||
//"disallowSpaceAfterBinaryOperators": [","],
|
||||
"disallowSpaceAfterPrefixUnaryOperators": ["++", "--", "+", "-", "~", "!"],
|
||||
"disallowSpaceBeforePostfixUnaryOperators": ["++", "--"],
|
||||
"requireSpaceBeforeBinaryOperators": ["+", "-", "/", "*", "=", "==", "===", "!=", "!=="],
|
||||
"requireSpaceAfterBinaryOperators": ["?", ">", ",", ">=", "<=", "<", "+", "-", "/", "*", "=", "==", "===", "!=", "!=="],
|
||||
//"validateIndentation": 4,
|
||||
//"validateQuoteMarks": { "mark": "\"", "escape": true },
|
||||
"disallowMixedSpacesAndTabs": true,
|
||||
"disallowKeywordsOnNewLine": ["else", "catch"]
|
||||
|
||||
};
|
17
tasks/jshint.js
Normal file
@ -0,0 +1,17 @@
|
||||
var srcDir = __dirname + "/../";
|
||||
|
||||
module.exports = {
|
||||
options: {
|
||||
force: true
|
||||
},
|
||||
all: [
|
||||
srcDir + "*.js",
|
||||
srcDir + "lib/*.js",
|
||||
srcDir + "adapter/example/*.js",
|
||||
srcDir + "tasks/**/*.js",
|
||||
srcDir + "www/**/*.js",
|
||||
'!' + srcDir + "www/lib/**/*.js",
|
||||
'!' + srcDir + 'node_modules/**/*.js',
|
||||
'!' + srcDir + 'adapter/*/node_modules/**/*.js'
|
||||
]
|
||||
};
|
91
test/testPackageFiles.js
Normal file
@ -0,0 +1,91 @@
|
||||
/* jshint -W097 */
|
||||
/* jshint strict:false */
|
||||
/* jslint node: true */
|
||||
/* jshint expr: true */
|
||||
var expect = require('chai').expect;
|
||||
var fs = require('fs');
|
||||
|
||||
describe('Test package.json and io-package.json', function() {
|
||||
it('Test package files', function (done) {
|
||||
console.log();
|
||||
|
||||
var fileContentIOPackage = fs.readFileSync(__dirname + '/../io-package.json', 'utf8');
|
||||
var ioPackage = JSON.parse(fileContentIOPackage);
|
||||
|
||||
var fileContentNPMPackage = fs.readFileSync(__dirname + '/../package.json', 'utf8');
|
||||
var npmPackage = JSON.parse(fileContentNPMPackage);
|
||||
|
||||
expect(ioPackage).to.be.an('object');
|
||||
expect(npmPackage).to.be.an('object');
|
||||
|
||||
expect(ioPackage.common.version, 'ERROR: Version number in io-package.json needs to exist').to.exist;
|
||||
expect(npmPackage.version, 'ERROR: Version number in package.json needs to exist').to.exist;
|
||||
|
||||
expect(ioPackage.common.version, 'ERROR: Version numbers in package.json and io-package.json needs to match').to.be.equal(npmPackage.version);
|
||||
|
||||
if (!ioPackage.common.news || !ioPackage.common.news[ioPackage.common.version]) {
|
||||
console.log('WARNING: No news entry for current version exists in io-package.json, no rollback in Admin possible!');
|
||||
console.log();
|
||||
}
|
||||
|
||||
expect(npmPackage.author, 'ERROR: Author in package.json needs to exist').to.exist;
|
||||
expect(ioPackage.common.authors, 'ERROR: Authors in io-package.json needs to exist').to.exist;
|
||||
|
||||
if (ioPackage.common.name.indexOf('template') !== 0) {
|
||||
if (Array.isArray(ioPackage.common.authors)) {
|
||||
expect(ioPackage.common.authors.length, 'ERROR: Author in io-package.json needs to be set').to.not.be.equal(0);
|
||||
if (ioPackage.common.authors.length === 1) {
|
||||
expect(ioPackage.common.authors[0], 'ERROR: Author in io-package.json needs to be a real name').to.not.be.equal('my Name <my@email.com>');
|
||||
}
|
||||
}
|
||||
else {
|
||||
expect(ioPackage.common.authors, 'ERROR: Author in io-package.json needs to be a real name').to.not.be.equal('my Name <my@email.com>');
|
||||
}
|
||||
}
|
||||
else {
|
||||
console.log('WARNING: Testing for set authors field in io-package skipped because template adapter');
|
||||
console.log();
|
||||
}
|
||||
expect(fs.existsSync(__dirname + '/../README.md'), 'ERROR: README.md needs to exist! Please create one with description, detail information and changelog. English is mandatory.').to.be.true;
|
||||
if (!ioPackage.common.titleLang || typeof ioPackage.common.titleLang !== 'object') {
|
||||
console.log('WARNING: titleLang is not existing in io-package.json. Please add');
|
||||
console.log();
|
||||
}
|
||||
if (
|
||||
ioPackage.common.title.indexOf('yunkong2') !== -1 ||
|
||||
ioPackage.common.title.indexOf('yunkong2') !== -1 ||
|
||||
ioPackage.common.title.indexOf('adapter') !== -1 ||
|
||||
ioPackage.common.title.indexOf('Adapter') !== -1
|
||||
) {
|
||||
console.log('WARNING: title contains Adapter or yunkong2. It is clear anyway, that it is adapter for yunkong2.');
|
||||
console.log();
|
||||
}
|
||||
|
||||
if (ioPackage.common.name.indexOf('vis-') !== 0) {
|
||||
if (!ioPackage.common.materialize || !fs.existsSync(__dirname + '/../admin/index_m.html') || !fs.existsSync(__dirname + '/../gulpfile.js')) {
|
||||
console.log('WARNING: Admin3 support is missing! Please add it');
|
||||
console.log();
|
||||
}
|
||||
if (ioPackage.common.materialize) {
|
||||
expect(fs.existsSync(__dirname + '/../admin/index_m.html'), 'Admin3 support is enabled in io-package.json, but index_m.html is missing!').to.be.true;
|
||||
}
|
||||
}
|
||||
|
||||
var licenseFileExists = fs.existsSync(__dirname + '/../LICENSE');
|
||||
var fileContentReadme = fs.readFileSync(__dirname + '/../README.md', 'utf8');
|
||||
if (fileContentReadme.indexOf('## Changelog') === -1) {
|
||||
console.log('Warning: The README.md should have a section ## Changelog');
|
||||
console.log();
|
||||
}
|
||||
expect((licenseFileExists || fileContentReadme.indexOf('## License') !== -1), 'A LICENSE must exist as LICENSE file or as part of the README.md').to.be.true;
|
||||
if (!licenseFileExists) {
|
||||
console.log('Warning: The License should also exist as LICENSE file');
|
||||
console.log();
|
||||
}
|
||||
if (fileContentReadme.indexOf('## License') === -1) {
|
||||
console.log('Warning: The README.md should also have a section ## License to be shown in Admin3');
|
||||
console.log();
|
||||
}
|
||||
done();
|
||||
});
|
||||
});
|
1106
widgets/timeandweather.html
Normal file
431
widgets/timeandweather/css/flipclock.css
Normal file
@ -0,0 +1,431 @@
|
||||
/* Get the bourbon mixin from http://bourbon.io */
|
||||
/* Reset */
|
||||
.flip-clock-wrapper * {
|
||||
-webkit-box-sizing: border-box;
|
||||
-moz-box-sizing: border-box;
|
||||
-ms-box-sizing: border-box;
|
||||
-o-box-sizing: border-box;
|
||||
box-sizing: border-box;
|
||||
-webkit-backface-visibility: hidden;
|
||||
-moz-backface-visibility: hidden;
|
||||
-ms-backface-visibility: hidden;
|
||||
-o-backface-visibility: hidden;
|
||||
backface-visibility: hidden;
|
||||
}
|
||||
|
||||
.flip-clock-wrapper a {
|
||||
cursor: pointer;
|
||||
text-decoration: none;
|
||||
color: #ccc; }
|
||||
|
||||
.flip-clock-wrapper a:hover {
|
||||
color: #fff; }
|
||||
|
||||
.flip-clock-wrapper ul {
|
||||
list-style: none; }
|
||||
|
||||
.flip-clock-wrapper.clearfix:before,
|
||||
.flip-clock-wrapper.clearfix:after {
|
||||
content: " ";
|
||||
display: table; }
|
||||
|
||||
.flip-clock-wrapper.clearfix:after {
|
||||
clear: both; }
|
||||
|
||||
.flip-clock-wrapper.clearfix {
|
||||
*zoom: 1; }
|
||||
|
||||
/* Main */
|
||||
.flip-clock-wrapper {
|
||||
font: normal 11px "Helvetica Neue", Helvetica, sans-serif;
|
||||
-webkit-user-select: none; }
|
||||
|
||||
.flip-clock-meridium {
|
||||
background: none !important;
|
||||
box-shadow: 0 0 0 !important;
|
||||
font-size: 36px !important; }
|
||||
|
||||
.flip-clock-meridium a { color: #313333; }
|
||||
|
||||
.flip-clock-wrapper {
|
||||
text-align: center;
|
||||
position: relative;
|
||||
width: 100%;
|
||||
margin: 1em;
|
||||
}
|
||||
|
||||
.flip-clock-wrapper:before,
|
||||
.flip-clock-wrapper:after {
|
||||
content: " "; /* 1 */
|
||||
display: table; /* 2 */
|
||||
}
|
||||
.flip-clock-wrapper:after {
|
||||
clear: both;
|
||||
}
|
||||
|
||||
/* Skeleton */
|
||||
.flip-clock-wrapper ul {
|
||||
position: relative;
|
||||
float: left;
|
||||
margin: 5px;
|
||||
width: 60px;
|
||||
height: 90px;
|
||||
font-size: 80px;
|
||||
font-weight: bold;
|
||||
line-height: 87px;
|
||||
border-radius: 6px;
|
||||
background: #000;
|
||||
}
|
||||
|
||||
.flip-clock-wrapper ul li {
|
||||
z-index: 1;
|
||||
position: absolute;
|
||||
left: 0;
|
||||
top: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
line-height: 87px;
|
||||
text-decoration: none !important;
|
||||
}
|
||||
|
||||
.flip-clock-wrapper ul li:first-child {
|
||||
z-index: 2; }
|
||||
|
||||
.flip-clock-wrapper ul li a {
|
||||
display: block;
|
||||
height: 100%;
|
||||
-webkit-perspective: 200px;
|
||||
-moz-perspective: 200px;
|
||||
perspective: 200px;
|
||||
margin: 0 !important;
|
||||
overflow: visible !important;
|
||||
cursor: default !important; }
|
||||
|
||||
.flip-clock-wrapper ul li a div {
|
||||
z-index: 1;
|
||||
position: absolute;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
height: 50%;
|
||||
font-size: 80px;
|
||||
overflow: hidden;
|
||||
outline: 1px solid transparent; }
|
||||
|
||||
.flip-clock-wrapper ul li a div .shadow {
|
||||
position: absolute;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
z-index: 2; }
|
||||
|
||||
.flip-clock-wrapper ul li a div.up {
|
||||
-webkit-transform-origin: 50% 100%;
|
||||
-moz-transform-origin: 50% 100%;
|
||||
-ms-transform-origin: 50% 100%;
|
||||
-o-transform-origin: 50% 100%;
|
||||
transform-origin: 50% 100%;
|
||||
top: 0; }
|
||||
|
||||
.flip-clock-wrapper ul li a div.up:after {
|
||||
content: "";
|
||||
position: absolute;
|
||||
top: 44px;
|
||||
left: 0;
|
||||
z-index: 5;
|
||||
width: 100%;
|
||||
height: 3px;
|
||||
background-color: #000;
|
||||
background-color: rgba(0, 0, 0, 0.4); }
|
||||
|
||||
.flip-clock-wrapper ul li a div.down {
|
||||
-webkit-transform-origin: 50% 0;
|
||||
-moz-transform-origin: 50% 0;
|
||||
-ms-transform-origin: 50% 0;
|
||||
-o-transform-origin: 50% 0;
|
||||
transform-origin: 50% 0;
|
||||
bottom: 0;
|
||||
border-bottom-left-radius: 6px;
|
||||
border-bottom-right-radius: 6px;
|
||||
}
|
||||
|
||||
.flip-clock-wrapper ul li a div div.inn {
|
||||
position: absolute;
|
||||
left: 0;
|
||||
z-index: 1;
|
||||
width: 100%;
|
||||
height: 200%;
|
||||
color: #ccc;
|
||||
text-shadow: 0 1px 2px #000;
|
||||
text-align: center;
|
||||
background-color: #333;
|
||||
border-radius: 6px;
|
||||
font-size: 70px; }
|
||||
|
||||
.flip-clock-wrapper ul li a div.up div.inn {
|
||||
top: 0; }
|
||||
|
||||
.flip-clock-wrapper ul li a div.down div.inn {
|
||||
bottom: 0; }
|
||||
|
||||
/* PLAY */
|
||||
.flip-clock-wrapper ul.play li.flip-clock-before {
|
||||
z-index: 3; }
|
||||
|
||||
.flip-clock-wrapper .flip { box-shadow: 0 2px 5px rgba(0, 0, 0, 0.7); }
|
||||
|
||||
.flip-clock-wrapper ul.play li.flip-clock-active {
|
||||
-webkit-animation: asd 0.5s 0.5s linear both;
|
||||
-moz-animation: asd 0.5s 0.5s linear both;
|
||||
animation: asd 0.5s 0.5s linear both;
|
||||
z-index: 5; }
|
||||
|
||||
.flip-clock-divider {
|
||||
float: left;
|
||||
display: inline-block;
|
||||
position: relative;
|
||||
width: 20px;
|
||||
height: 100px; }
|
||||
|
||||
.flip-clock-divider:first-child {
|
||||
width: 0; }
|
||||
|
||||
.flip-clock-dot {
|
||||
display: block;
|
||||
background: #323434;
|
||||
width: 10px;
|
||||
height: 10px;
|
||||
position: absolute;
|
||||
border-radius: 50%;
|
||||
box-shadow: 0 0 5px rgba(0, 0, 0, 0.5);
|
||||
left: 5px; }
|
||||
|
||||
.flip-clock-divider .flip-clock-label {
|
||||
position: absolute;
|
||||
top: -1.5em;
|
||||
right: -86px;
|
||||
color: black;
|
||||
text-shadow: none; }
|
||||
|
||||
.flip-clock-divider.minutes .flip-clock-label {
|
||||
right: -88px; }
|
||||
|
||||
.flip-clock-divider.seconds .flip-clock-label {
|
||||
right: -91px; }
|
||||
|
||||
.flip-clock-dot.top {
|
||||
top: 30px; }
|
||||
|
||||
.flip-clock-dot.bottom {
|
||||
bottom: 30px; }
|
||||
|
||||
@-webkit-keyframes asd {
|
||||
0% {
|
||||
z-index: 2; }
|
||||
|
||||
20% {
|
||||
z-index: 4; }
|
||||
|
||||
100% {
|
||||
z-index: 4; } }
|
||||
|
||||
@-moz-keyframes asd {
|
||||
0% {
|
||||
z-index: 2; }
|
||||
|
||||
20% {
|
||||
z-index: 4; }
|
||||
|
||||
100% {
|
||||
z-index: 4; } }
|
||||
|
||||
@-o-keyframes asd {
|
||||
0% {
|
||||
z-index: 2; }
|
||||
|
||||
20% {
|
||||
z-index: 4; }
|
||||
|
||||
100% {
|
||||
z-index: 4; } }
|
||||
|
||||
@keyframes asd {
|
||||
0% {
|
||||
z-index: 2; }
|
||||
|
||||
20% {
|
||||
z-index: 4; }
|
||||
|
||||
100% {
|
||||
z-index: 4; } }
|
||||
|
||||
.flip-clock-wrapper ul.play li.flip-clock-active .down {
|
||||
z-index: 2;
|
||||
-webkit-animation: turn 0.5s 0.5s linear both;
|
||||
-moz-animation: turn 0.5s 0.5s linear both;
|
||||
animation: turn 0.5s 0.5s linear both; }
|
||||
|
||||
@-webkit-keyframes turn {
|
||||
0% {
|
||||
-webkit-transform: rotateX(90deg); }
|
||||
|
||||
100% {
|
||||
-webkit-transform: rotateX(0deg); } }
|
||||
|
||||
@-moz-keyframes turn {
|
||||
0% {
|
||||
-moz-transform: rotateX(90deg); }
|
||||
|
||||
100% {
|
||||
-moz-transform: rotateX(0deg); } }
|
||||
|
||||
@-o-keyframes turn {
|
||||
0% {
|
||||
-o-transform: rotateX(90deg); }
|
||||
|
||||
100% {
|
||||
-o-transform: rotateX(0deg); } }
|
||||
|
||||
@keyframes turn {
|
||||
0% {
|
||||
transform: rotateX(90deg); }
|
||||
|
||||
100% {
|
||||
transform: rotateX(0deg); } }
|
||||
|
||||
.flip-clock-wrapper ul.play li.flip-clock-before .up {
|
||||
z-index: 2;
|
||||
-webkit-animation: turn2 0.5s linear both;
|
||||
-moz-animation: turn2 0.5s linear both;
|
||||
animation: turn2 0.5s linear both; }
|
||||
|
||||
@-webkit-keyframes turn2 {
|
||||
0% {
|
||||
-webkit-transform: rotateX(0deg); }
|
||||
|
||||
100% {
|
||||
-webkit-transform: rotateX(-90deg); } }
|
||||
|
||||
@-moz-keyframes turn2 {
|
||||
0% {
|
||||
-moz-transform: rotateX(0deg); }
|
||||
|
||||
100% {
|
||||
-moz-transform: rotateX(-90deg); } }
|
||||
|
||||
@-o-keyframes turn2 {
|
||||
0% {
|
||||
-o-transform: rotateX(0deg); }
|
||||
|
||||
100% {
|
||||
-o-transform: rotateX(-90deg); } }
|
||||
|
||||
@keyframes turn2 {
|
||||
0% {
|
||||
transform: rotateX(0deg); }
|
||||
|
||||
100% {
|
||||
transform: rotateX(-90deg); } }
|
||||
|
||||
.flip-clock-wrapper ul li.flip-clock-active {
|
||||
z-index: 3; }
|
||||
|
||||
/* SHADOW */
|
||||
.flip-clock-wrapper ul.play li.flip-clock-before .up .shadow {
|
||||
background: -moz-linear-gradient(top, rgba(0, 0, 0, 0.1) 0%, black 100%);
|
||||
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%, rgba(0, 0, 0, 0.1)), color-stop(100%, black));
|
||||
background: linear, top, rgba(0, 0, 0, 0.1) 0%, black 100%;
|
||||
background: -o-linear-gradient(top, rgba(0, 0, 0, 0.1) 0%, black 100%);
|
||||
background: -ms-linear-gradient(top, rgba(0, 0, 0, 0.1) 0%, black 100%);
|
||||
background: linear, to bottom, rgba(0, 0, 0, 0.1) 0%, black 100%;
|
||||
-webkit-animation: show 0.5s linear both;
|
||||
-moz-animation: show 0.5s linear both;
|
||||
animation: show 0.5s linear both; }
|
||||
|
||||
.flip-clock-wrapper ul.play li.flip-clock-active .up .shadow {
|
||||
background: -moz-linear-gradient(top, rgba(0, 0, 0, 0.1) 0%, black 100%);
|
||||
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%, rgba(0, 0, 0, 0.1)), color-stop(100%, black));
|
||||
background: linear, top, rgba(0, 0, 0, 0.1) 0%, black 100%;
|
||||
background: -o-linear-gradient(top, rgba(0, 0, 0, 0.1) 0%, black 100%);
|
||||
background: -ms-linear-gradient(top, rgba(0, 0, 0, 0.1) 0%, black 100%);
|
||||
background: linear, to bottom, rgba(0, 0, 0, 0.1) 0%, black 100%;
|
||||
-webkit-animation: hide 0.5s 0.3s linear both;
|
||||
-moz-animation: hide 0.5s 0.3s linear both;
|
||||
animation: hide 0.5s 0.3s linear both; }
|
||||
|
||||
/*DOWN*/
|
||||
.flip-clock-wrapper ul.play li.flip-clock-before .down .shadow {
|
||||
background: -moz-linear-gradient(top, black 0%, rgba(0, 0, 0, 0.1) 100%);
|
||||
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%, black), color-stop(100%, rgba(0, 0, 0, 0.1)));
|
||||
background: linear, top, black 0%, rgba(0, 0, 0, 0.1) 100%;
|
||||
background: -o-linear-gradient(top, black 0%, rgba(0, 0, 0, 0.1) 100%);
|
||||
background: -ms-linear-gradient(top, black 0%, rgba(0, 0, 0, 0.1) 100%);
|
||||
background: linear, to bottom, black 0%, rgba(0, 0, 0, 0.1) 100%;
|
||||
-webkit-animation: show 0.5s linear both;
|
||||
-moz-animation: show 0.5s linear both;
|
||||
animation: show 0.5s linear both; }
|
||||
|
||||
.flip-clock-wrapper ul.play li.flip-clock-active .down .shadow {
|
||||
background: -moz-linear-gradient(top, black 0%, rgba(0, 0, 0, 0.1) 100%);
|
||||
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%, black), color-stop(100%, rgba(0, 0, 0, 0.1)));
|
||||
background: linear, top, black 0%, rgba(0, 0, 0, 0.1) 100%;
|
||||
background: -o-linear-gradient(top, black 0%, rgba(0, 0, 0, 0.1) 100%);
|
||||
background: -ms-linear-gradient(top, black 0%, rgba(0, 0, 0, 0.1) 100%);
|
||||
background: linear, to bottom, black 0%, rgba(0, 0, 0, 0.1) 100%;
|
||||
-webkit-animation: hide 0.5s 0.3s linear both;
|
||||
-moz-animation: hide 0.5s 0.3s linear both;
|
||||
animation: hide 0.5s 0.2s linear both; }
|
||||
|
||||
@-webkit-keyframes show {
|
||||
0% {
|
||||
opacity: 0; }
|
||||
|
||||
100% {
|
||||
opacity: 1; } }
|
||||
|
||||
@-moz-keyframes show {
|
||||
0% {
|
||||
opacity: 0; }
|
||||
|
||||
100% {
|
||||
opacity: 1; } }
|
||||
|
||||
@-o-keyframes show {
|
||||
0% {
|
||||
opacity: 0; }
|
||||
|
||||
100% {
|
||||
opacity: 1; } }
|
||||
|
||||
@keyframes show {
|
||||
0% {
|
||||
opacity: 0; }
|
||||
|
||||
100% {
|
||||
opacity: 1; } }
|
||||
|
||||
@-webkit-keyframes hide {
|
||||
0% {
|
||||
opacity: 1; }
|
||||
|
||||
100% {
|
||||
opacity: 0; } }
|
||||
|
||||
@-moz-keyframes hide {
|
||||
0% {
|
||||
opacity: 1; }
|
||||
|
||||
100% {
|
||||
opacity: 0; } }
|
||||
|
||||
@-o-keyframes hide {
|
||||
0% {
|
||||
opacity: 1; }
|
||||
|
||||
100% {
|
||||
opacity: 0; } }
|
||||
|
||||
@keyframes hide {
|
||||
0% {
|
||||
opacity: 1; }
|
||||
|
||||
100% {
|
||||
opacity: 0; } }
|
248
widgets/timeandweather/css/jquery.jdigiclock.css
Normal file
@ -0,0 +1,248 @@
|
||||
.dc_plugin_container {
|
||||
width:500px;
|
||||
height:420px;
|
||||
position:relative;
|
||||
overflow:hidden;
|
||||
font-family:Arial, Verdana, Tahoma, Helvetica, sans-serif;
|
||||
color:#fff;
|
||||
}
|
||||
|
||||
.dc_plugin_container p {
|
||||
margin:0;
|
||||
padding:0;
|
||||
}
|
||||
|
||||
.dc_left_arrow, .dc_right_arrow {
|
||||
position:absolute;
|
||||
top:200px;
|
||||
z-index:200;
|
||||
cursor:pointer;
|
||||
}
|
||||
|
||||
.dc_left_arrow {
|
||||
left:5px;
|
||||
}
|
||||
|
||||
.dc_right_arrow {
|
||||
right:5px;
|
||||
}
|
||||
|
||||
.dc_digital_container {
|
||||
width:500px;
|
||||
height:360px;
|
||||
background:url(../img/background.png) 50% 40px no-repeat;
|
||||
position:absolute;
|
||||
top:40px;
|
||||
left:0;
|
||||
z-index:98;
|
||||
}
|
||||
|
||||
|
||||
.dc_clock {
|
||||
float:left;
|
||||
margin-left:48px;
|
||||
}
|
||||
|
||||
.dc_hours, .dc_minutes {
|
||||
width:200px;
|
||||
height:200px;
|
||||
float:left;
|
||||
position:relative;
|
||||
}
|
||||
|
||||
.dc_minutes {
|
||||
margin-left:4px;
|
||||
}
|
||||
|
||||
.dc_hours_bg, .dc_minutes_bg {
|
||||
width:100%;
|
||||
height:100%;
|
||||
position:absolute;
|
||||
top:0;
|
||||
left:0;
|
||||
z-index:99;
|
||||
}
|
||||
|
||||
.dc_first_digit {
|
||||
width:80px;
|
||||
height:100%;
|
||||
position:absolute;
|
||||
top:0;
|
||||
left:20px;
|
||||
z-index:100;
|
||||
}
|
||||
|
||||
.dc_second_digit {
|
||||
width:80px;
|
||||
height:100%;
|
||||
position:absolute;
|
||||
top:0;
|
||||
left:100px;
|
||||
z-index:100;
|
||||
}
|
||||
|
||||
.dc_line {
|
||||
width:175px;
|
||||
height:2px;
|
||||
background:#efefef;
|
||||
position:absolute;
|
||||
top:97px;
|
||||
left:12px;
|
||||
z-index:101;
|
||||
font-size:1px;
|
||||
}
|
||||
|
||||
.dc_am_pm {
|
||||
position:absolute;
|
||||
top:156px;
|
||||
left:130px;
|
||||
z-index:110;
|
||||
}
|
||||
|
||||
.dc_weather {
|
||||
width:100%;
|
||||
height:206px;
|
||||
position:absolute;
|
||||
top:140px;
|
||||
left:0;
|
||||
z-index:105;
|
||||
color:#fff;
|
||||
}
|
||||
|
||||
.dc_weather .dc_local, .dc_weather .dc_loading {
|
||||
float:left;
|
||||
margin:65px 0 0 45px;
|
||||
}
|
||||
.dc_city_main {
|
||||
font-weight:bold;
|
||||
font-size:12pt;
|
||||
}
|
||||
.dc_city {
|
||||
font-weight:bold;
|
||||
font-size:12pt;
|
||||
position: absolute;
|
||||
top: 180px
|
||||
}
|
||||
.dc_actual {
|
||||
position: absolute;
|
||||
top: 120px;
|
||||
left: 60px;
|
||||
font-size: 32px;
|
||||
}
|
||||
.dc_temp {
|
||||
font-size:30pt;
|
||||
padding:0;
|
||||
}
|
||||
|
||||
.dc_temp .dc_metric {
|
||||
margin-left:-3px;
|
||||
}
|
||||
|
||||
.dc_weather .dc_temp {
|
||||
float:right;
|
||||
margin:65px 45px 0 0;
|
||||
text-align:right;
|
||||
}
|
||||
|
||||
.dc_weather .dc_date {
|
||||
font-size:11pt;
|
||||
padding-right:2px;
|
||||
}
|
||||
|
||||
.dc_forecast_container {
|
||||
width:500px;
|
||||
height:400px;
|
||||
background:url(../img/background_forecast.png) 50% 100% no-repeat;
|
||||
position:absolute;
|
||||
top:0;
|
||||
left:500px;
|
||||
z-index:98;
|
||||
}
|
||||
|
||||
.dc_forecast_container #current {
|
||||
width:400px;
|
||||
height:240px;
|
||||
margin-left:50px;
|
||||
position:relative;
|
||||
}
|
||||
|
||||
.dc_forecast_container .dc_loading {
|
||||
margin:130px 0 0 70px;
|
||||
}
|
||||
|
||||
.dc_forecast_container .dc_current .dc_temp, .dc_forecast_container .dc_current .dc_high_low {
|
||||
width:116px;
|
||||
text-align:center;
|
||||
}
|
||||
|
||||
.dc_forecast_container .dc_current .dc_temp {
|
||||
font-size:32pt;
|
||||
margin-top:110px;
|
||||
float:left
|
||||
}
|
||||
|
||||
.dc_forecast_container .dc_current .dc_high_low {
|
||||
font-size:12pt;
|
||||
clear:both;
|
||||
top: 160px;
|
||||
left: 40px;
|
||||
position: absolute;
|
||||
}
|
||||
|
||||
.dc_forecast_container .dc_current .dc_city, .dc_forecast_container .dc_current .dc_text {
|
||||
width:100%;
|
||||
text-align:center;
|
||||
}
|
||||
.dc_image {
|
||||
top: 0px;
|
||||
left: 15px;
|
||||
height: 230px;
|
||||
position: absolute;
|
||||
width: 500px;
|
||||
}
|
||||
.dc_forecast_container .dc_current .dc_text {
|
||||
margin-top:6px;
|
||||
position: absolute;
|
||||
top: 205px;
|
||||
}
|
||||
|
||||
.dc_forecast_container .dc_forecast {
|
||||
width:400px;
|
||||
height:122px;
|
||||
list-style:none;
|
||||
margin:0 0 0 50px;
|
||||
padding:0;
|
||||
}
|
||||
|
||||
.dc_forecast_container .dc_forecast li {
|
||||
width:25%;
|
||||
height:100%;
|
||||
float:left;
|
||||
text-align:center;
|
||||
}
|
||||
|
||||
.dc_forecast_container .dc_forecast li p {
|
||||
width:100%;
|
||||
height:30px;
|
||||
margin:0;
|
||||
padding:0;
|
||||
font-size:11pt;
|
||||
line-height:30px;
|
||||
}
|
||||
|
||||
.dc_forecast_container .dc_forecast li img {
|
||||
width:96px;
|
||||
margin: 0 20px;
|
||||
}
|
||||
|
||||
.dc_forecast_container .dc_update {
|
||||
text-align:center;
|
||||
margin-top:10px;
|
||||
font-size:11px;
|
||||
}
|
||||
|
||||
.dc_forecast_container .dc_update img {
|
||||
margin:-2px 4px 0 0;
|
||||
vertical-align:middle;
|
||||
cursor:pointer;
|
||||
}
|
22
widgets/timeandweather/css/simpleclock.css
Normal file
@ -0,0 +1,22 @@
|
||||
.clock {
|
||||
text-shadow:3px 3px 4px rgba(0,0,0,0.9);
|
||||
font-weight:bold;
|
||||
color:#969696;
|
||||
letter-spacing:-3pt;
|
||||
word-spacing:-10pt;
|
||||
text-align:left;
|
||||
font-family:trebuchet MS, sans-serif;
|
||||
font-size: 80px;
|
||||
overflow: visible;
|
||||
}
|
||||
|
||||
.date {
|
||||
text-shadow:3px 3px 4px rgba(0,0,0,0.9);
|
||||
font-weight:bold;
|
||||
color:#969696;
|
||||
letter-spacing:-1pt;
|
||||
text-align:left;
|
||||
font-family:trebuchet MS, sans-serif;
|
||||
font-size: 26px;
|
||||
overflow: visible;
|
||||
}
|
63
widgets/timeandweather/css/yahoo.css
Normal file
@ -0,0 +1,63 @@
|
||||
@charset "UTF-8";
|
||||
/**
|
||||
* Stylesheet: example.css
|
||||
*
|
||||
* (c) 2011-2012 Zazar Ltd
|
||||
*
|
||||
* Description: Stylesheet for examples
|
||||
*
|
||||
**/
|
||||
.weatherFeed {
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
font-size: 90%;
|
||||
overflow: hidden;
|
||||
-webkit-border-radius: 20px;
|
||||
-moz-border-radius: 20px;
|
||||
border-radius: 20px;
|
||||
}
|
||||
.weatherFeed a { color: #888; }
|
||||
.weatherFeed a:hover {
|
||||
color: #000;
|
||||
text-decoration: none;
|
||||
}
|
||||
.weatherItem {
|
||||
padding: 0.8em;
|
||||
text-align: right;
|
||||
}
|
||||
.weatherCity { text-transform: uppercase; }
|
||||
.weatherTemp {
|
||||
font-size: 2.8em;
|
||||
font-weight: bold;
|
||||
}
|
||||
.weatherDesc, .weatherCity, .weatherForecastDay { font-weight: bold; }
|
||||
.weatherDesc { margin-bottom: 0.4em; }
|
||||
.weatherRange, .weatherWind, .weatherLink, .weatherForecastItem { font-size: 0.8em; }
|
||||
.weatherLink, .weatherForecastItem {
|
||||
margin-top: 0.5em;
|
||||
text-align: left;
|
||||
}
|
||||
.weatherForecastItem {
|
||||
padding: 0.5em 0.5em 0.5em 60px;
|
||||
background-color: #000;
|
||||
background-position: left center;
|
||||
-webkit-border-radius: 5px;
|
||||
-moz-border-radius: 5px;
|
||||
border-radius: 5px;
|
||||
}
|
||||
.weatherForecastDay { font-size: 1.1em; }
|
||||
|
||||
.odd { background-color: #e8e8fc; }
|
||||
.even { background-color: #d4d4e8; }
|
||||
|
||||
.day {
|
||||
border: 4px solid #555;
|
||||
background: #222 url(../img/bg.jpg) repeat-x;
|
||||
color: #fff
|
||||
}
|
||||
.day a { color: #555; }
|
||||
|
||||
.night {
|
||||
border: 4px solid #555;
|
||||
background: #222 url(../img/bg.jpg) repeat-x;
|
||||
}
|
||||
.night a:hover { color: #fff; }
|
10
widgets/timeandweather/doc.html
Normal file
@ -0,0 +1,10 @@
|
||||
<html>
|
||||
<head>
|
||||
<link rel="stylesheet" href="../../css/doc.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
BIN
widgets/timeandweather/img/Prev_CoolClock.png
Normal file
After Width: | Height: | Size: 6.4 KiB |
BIN
widgets/timeandweather/img/Prev_FlipClock.png
Normal file
After Width: | Height: | Size: 3.0 KiB |
BIN
widgets/timeandweather/img/Prev_HTCWeather.png
Normal file
After Width: | Height: | Size: 12 KiB |
BIN
widgets/timeandweather/img/Prev_YahooWeather.png
Normal file
After Width: | Height: | Size: 24 KiB |
BIN
widgets/timeandweather/img/Prev_tplSegmentClock.png
Normal file
After Width: | Height: | Size: 5.0 KiB |
BIN
widgets/timeandweather/img/Prev_tplSvgClock.png
Normal file
After Width: | Height: | Size: 6.4 KiB |
BIN
widgets/timeandweather/img/background.png
Normal file
After Width: | Height: | Size: 132 KiB |
BIN
widgets/timeandweather/img/background_forecast.png
Normal file
After Width: | Height: | Size: 64 KiB |
BIN
widgets/timeandweather/img/bg.jpg
Normal file
After Width: | Height: | Size: 805 B |
BIN
widgets/timeandweather/img/clock/0-1.png
Normal file
After Width: | Height: | Size: 4.7 KiB |
BIN
widgets/timeandweather/img/clock/0-2.png
Normal file
After Width: | Height: | Size: 4.2 KiB |
BIN
widgets/timeandweather/img/clock/0-3.png
Normal file
After Width: | Height: | Size: 3.7 KiB |
BIN
widgets/timeandweather/img/clock/0.png
Normal file
After Width: | Height: | Size: 4.8 KiB |
BIN
widgets/timeandweather/img/clock/001-1.png
Normal file
After Width: | Height: | Size: 3.5 KiB |
BIN
widgets/timeandweather/img/clock/001-2.png
Normal file
After Width: | Height: | Size: 3.8 KiB |
BIN
widgets/timeandweather/img/clock/001-3.png
Normal file
After Width: | Height: | Size: 4.0 KiB |
BIN
widgets/timeandweather/img/clock/01-1.png
Normal file
After Width: | Height: | Size: 4.9 KiB |
BIN
widgets/timeandweather/img/clock/01-2.png
Normal file
After Width: | Height: | Size: 4.9 KiB |
BIN
widgets/timeandweather/img/clock/01-3.png
Normal file
After Width: | Height: | Size: 4.7 KiB |
BIN
widgets/timeandweather/img/clock/1-1.png
Normal file
After Width: | Height: | Size: 3.9 KiB |
BIN
widgets/timeandweather/img/clock/1-2.png
Normal file
After Width: | Height: | Size: 4.3 KiB |
BIN
widgets/timeandweather/img/clock/1-3.png
Normal file
After Width: | Height: | Size: 4.4 KiB |
BIN
widgets/timeandweather/img/clock/1.png
Normal file
After Width: | Height: | Size: 3.4 KiB |
BIN
widgets/timeandweather/img/clock/11-1.png
Normal file
After Width: | Height: | Size: 3.6 KiB |
BIN
widgets/timeandweather/img/clock/11-2.png
Normal file
After Width: | Height: | Size: 3.4 KiB |
BIN
widgets/timeandweather/img/clock/11-3.png
Normal file
After Width: | Height: | Size: 3.4 KiB |
BIN
widgets/timeandweather/img/clock/111-1.png
Normal file
After Width: | Height: | Size: 4.0 KiB |
BIN
widgets/timeandweather/img/clock/111-2.png
Normal file
After Width: | Height: | Size: 3.6 KiB |
BIN
widgets/timeandweather/img/clock/111-3.png
Normal file
After Width: | Height: | Size: 3.3 KiB |
BIN
widgets/timeandweather/img/clock/2-1.png
Normal file
After Width: | Height: | Size: 4.7 KiB |
BIN
widgets/timeandweather/img/clock/2-2.png
Normal file
After Width: | Height: | Size: 4.8 KiB |
BIN
widgets/timeandweather/img/clock/2-3.png
Normal file
After Width: | Height: | Size: 4.7 KiB |
BIN
widgets/timeandweather/img/clock/2.png
Normal file
After Width: | Height: | Size: 4.7 KiB |
BIN
widgets/timeandweather/img/clock/21-1.png
Normal file
After Width: | Height: | Size: 4.7 KiB |
BIN
widgets/timeandweather/img/clock/21-2.png
Normal file
After Width: | Height: | Size: 4.7 KiB |
BIN
widgets/timeandweather/img/clock/21-3.png
Normal file
After Width: | Height: | Size: 4.4 KiB |
BIN
widgets/timeandweather/img/clock/211-1.png
Normal file
After Width: | Height: | Size: 4.2 KiB |
BIN
widgets/timeandweather/img/clock/211-2.png
Normal file
After Width: | Height: | Size: 4.1 KiB |
BIN
widgets/timeandweather/img/clock/211-3.png
Normal file
After Width: | Height: | Size: 4.0 KiB |
BIN
widgets/timeandweather/img/clock/3-1.png
Normal file
After Width: | Height: | Size: 4.8 KiB |
BIN
widgets/timeandweather/img/clock/3-2.png
Normal file
After Width: | Height: | Size: 4.5 KiB |
BIN
widgets/timeandweather/img/clock/3-3.png
Normal file
After Width: | Height: | Size: 4.2 KiB |
BIN
widgets/timeandweather/img/clock/3.png
Normal file
After Width: | Height: | Size: 5.0 KiB |
BIN
widgets/timeandweather/img/clock/31-1.png
Normal file
After Width: | Height: | Size: 5.0 KiB |
BIN
widgets/timeandweather/img/clock/31-2.png
Normal file
After Width: | Height: | Size: 5.0 KiB |
BIN
widgets/timeandweather/img/clock/31-3.png
Normal file
After Width: | Height: | Size: 4.9 KiB |
BIN
widgets/timeandweather/img/clock/311-1.png
Normal file
After Width: | Height: | Size: 4.4 KiB |
BIN
widgets/timeandweather/img/clock/311-2.png
Normal file
After Width: | Height: | Size: 4.3 KiB |
BIN
widgets/timeandweather/img/clock/311-3.png
Normal file
After Width: | Height: | Size: 4.2 KiB |
BIN
widgets/timeandweather/img/clock/4-1.png
Normal file
After Width: | Height: | Size: 3.9 KiB |
BIN
widgets/timeandweather/img/clock/4-2.png
Normal file
After Width: | Height: | Size: 4.3 KiB |
BIN
widgets/timeandweather/img/clock/4-3.png
Normal file
After Width: | Height: | Size: 4.4 KiB |
BIN
widgets/timeandweather/img/clock/4.png
Normal file
After Width: | Height: | Size: 3.9 KiB |
BIN
widgets/timeandweather/img/clock/41-1.png
Normal file
After Width: | Height: | Size: 3.9 KiB |
BIN
widgets/timeandweather/img/clock/41-2.png
Normal file
After Width: | Height: | Size: 3.9 KiB |
BIN
widgets/timeandweather/img/clock/41-3.png
Normal file
After Width: | Height: | Size: 3.9 KiB |
BIN
widgets/timeandweather/img/clock/5-1.png
Normal file
After Width: | Height: | Size: 4.9 KiB |
BIN
widgets/timeandweather/img/clock/5-2.png
Normal file
After Width: | Height: | Size: 5.3 KiB |
BIN
widgets/timeandweather/img/clock/5-3.png
Normal file
After Width: | Height: | Size: 5.1 KiB |
BIN
widgets/timeandweather/img/clock/5.png
Normal file
After Width: | Height: | Size: 4.7 KiB |
BIN
widgets/timeandweather/img/clock/51-1.png
Normal file
After Width: | Height: | Size: 4.5 KiB |
BIN
widgets/timeandweather/img/clock/51-2.png
Normal file
After Width: | Height: | Size: 4.8 KiB |
BIN
widgets/timeandweather/img/clock/51-3.png
Normal file
After Width: | Height: | Size: 4.6 KiB |
BIN
widgets/timeandweather/img/clock/511-1.png
Normal file
After Width: | Height: | Size: 4.3 KiB |
BIN
widgets/timeandweather/img/clock/511-2.png
Normal file
After Width: | Height: | Size: 4.2 KiB |
BIN
widgets/timeandweather/img/clock/511-3.png
Normal file
After Width: | Height: | Size: 4.2 KiB |
BIN
widgets/timeandweather/img/clock/6-1.png
Normal file
After Width: | Height: | Size: 4.9 KiB |
BIN
widgets/timeandweather/img/clock/6-2.png
Normal file
After Width: | Height: | Size: 4.6 KiB |
BIN
widgets/timeandweather/img/clock/6-3.png
Normal file
After Width: | Height: | Size: 4.2 KiB |
BIN
widgets/timeandweather/img/clock/6.png
Normal file
After Width: | Height: | Size: 5.2 KiB |
BIN
widgets/timeandweather/img/clock/7-1.png
Normal file
After Width: | Height: | Size: 4.3 KiB |
BIN
widgets/timeandweather/img/clock/7-2.png
Normal file
After Width: | Height: | Size: 4.8 KiB |
BIN
widgets/timeandweather/img/clock/7-3.png
Normal file
After Width: | Height: | Size: 4.9 KiB |
BIN
widgets/timeandweather/img/clock/7.png
Normal file
After Width: | Height: | Size: 4.1 KiB |
BIN
widgets/timeandweather/img/clock/8-1.png
Normal file
After Width: | Height: | Size: 5.3 KiB |
BIN
widgets/timeandweather/img/clock/8-2.png
Normal file
After Width: | Height: | Size: 5.2 KiB |
BIN
widgets/timeandweather/img/clock/8-3.png
Normal file
After Width: | Height: | Size: 5.0 KiB |
BIN
widgets/timeandweather/img/clock/8.png
Normal file
After Width: | Height: | Size: 5.3 KiB |
BIN
widgets/timeandweather/img/clock/9-1.png
Normal file
After Width: | Height: | Size: 5.2 KiB |