...
 
Commits (5)
zh*
LICENSE*
bin/*.js
*.html
!test/index.html
*.min.js
*.sa.js
#data/*.json
src/*.json
*.min.js*
*.js.map
*copy*
*.php
src/*
!src/widget-src.js
x_legacy/
node_modules/
*.log
*.diff
composer.*
vendor/
*.js.map
*BAK*
*.js
i18n-texts.js
widget-run.js
[![Build status — Travis-CI][travis-icon]][travis]
[![GAAD-widget on Npmjs][npm-icon]][npm]
[![js-semistandard-style][semi-icon]][semi]
......@@ -13,7 +14,7 @@ The banner displays for a configurable period before and after the day.
> The purpose of GAAD is to get everyone talking, thinking and learning about digital
> (web, software, mobile, etc.) access/inclusion and people with different disabilities.
Built on [Datejs][].
[Blog post][blog]. Built on [Datejs][].
Note ~ this is not an official widget!
......@@ -58,7 +59,15 @@ npm test
## Usage
Via [RawGit][] - production / CDN:
Via [unpkg][] - production CDN:
```html
<div id="id-gaad"></div>
<script src="https://unpkg.com/gaad-widget@2.2.0-beta/build/GAAD.widget.js"></script>
```
Via [RawGit][] - production CDN:
```html
<div id="id-gaad"></div>
......@@ -105,6 +114,10 @@ Français (French):
<script src="build/GAAD.widget.js" data-gaad='{ "lang": "fr" }' ></script>
```
## WordPress
A [plugin for WordPress][wp].
## License
License: [MIT][].
......@@ -112,6 +125,7 @@ License: [MIT][].
Twitter: [@nfreear][], [@gbla11yday][].
[blog]: http://nick.freear.org.uk/2017/05/14/gaad-widget.html
[GAAD]: http://globalaccessibilityawarenessday.org/?utm_source=github&utm_campaign=gaad-widget
[@gbla11yday]: https://twitter.com/gbla11yday
[@nfreear]: https://twitter.com/nfreear
......@@ -124,13 +138,17 @@ Twitter: [@nfreear][], [@gbla11yday][].
[b/a]: https://github.com/nfreear/gaad-widget/issues/5 "Bug #5, Separate before and after messages (v 2.x)"
[ie]: https://github.com/nfreear/gaad-widget/issues/3#!-MSIE-9-11 "Bug #3, Browser compatibility"
[gist]: https://gist.github.com/nfreear/eef4be96147cb5c1182cbc9e595f2833
[wp]: https://gist.github.com/nfreear/e5520adbb930e537ef5fe2e0aab231d1 "WordPress plugin (PHP)"
[Datejs]: https://github.com/datejs/Datejs
[RawGit]: https://rawgit.com/
"Serves Git files with the correct mime-type; content delivery network (CDN)"
[MIT]: https://nfreear.mit-license.org/2017#!-gaad-widget "MIT License"
"RawGit serves Git files with the correct mime-type; a content delivery network (CDN)"
[unpkg]: https://unpkg.com/ "unpkg is a fast content delivery network for everything on npm"
[MIT]: https://nfreear.mit-license.org/2017#!-gaad-widget "MIT License | © Nick Freear 2017-04-27"
[travis]: https://travis-ci.org/nfreear/gaad-widget
[travis-icon]: https://api.travis-ci.org/nfreear/gaad-widget.svg
"Build status – Travis-CI (NPM/eslint)"
[semi]: https://github.com/Flet/semistandard
[semi-icon]: https://img.shields.io/badge/code%20style-semistandard-brightgreen.svg?style=flat-square
"Javascript coding style — 'semistandard'"
[npm]: https://npmjs.com/package/gaad-widget
[npm-icon]: https://img.shields.io/npm/v/gaad-widget
{
"//": "License: MIT. The data is provided \"as is\". I accept no responsibility for the accuracy or otherwise of the data, or any losses arising.",
"timestamp": "2017-05-21 10:29:48Z",
"timestamp": "2017-06-04 15:10:12Z",
"texts": {
"en": {
"name": "Global Accessibility Awareness Day (GAAD)",
"before": "Join us on Thursday May {d}{th}, {y} and mark the {x}th <a {at}>{g}</a>{g}</a>.",
"after": "Put next year's <a {at}>{g}</a>{g}</a>, Thursday May {d}{th}, {y}, in your diary. See you then!",
"before": "Join us on Thursday May {d}{th}, {y} and mark the {x}th <a {at}>{g}</a>.",
"after": "Put next year's <a {at}>{g}</a>, Thursday May {d}{th}, {y}, in your diary. See you then!",
"url": "http://globalaccessibilityawarenessday.org"
},
"fr": {
......
......@@ -15,6 +15,6 @@ Usage:
iframe.gaad-widget-ifr { width: 100%; height: 4.2em; border: none; }
</style>
<iframe src="https://cdn.rawgit.com/nfreear/gaad-widget/2.0-beta/embed/" class="gaad-widget-ifr"></iframe>
<iframe src="https://cdn.rawgit.com/nfreear/gaad-widget/2.2-beta/embed/" class="gaad-widget-ifr"></iframe>
-->
{
"name": "Global Accessibility Awareness Day (GAAD)",
"before": "Join us on Thursday May {d}{th}, {y} and mark the {x}th <a {at}>{g}</a>{g}</a>.",
"after": "Put next year's <a {at}>{g}</a>{g}</a>, Thursday May {d}{th}, {y}, in your diary. See you then!",
"before": "Join us on Thursday May {d}{th}, {y} and mark the {x}th <a {at}>{g}</a>.",
"after": "Put next year's <a {at}>{g}</a>, Thursday May {d}{th}, {y}, in your diary. See you then!",
"url": "http://globalaccessibilityawarenessday.org"
}
{
"name": "gaad-widget",
"version": "2.1.0-beta",
"version": "2.2.0-beta",
"description": "Display a banner-link to promote Global Accessibility Awareness Day (GAAD). Display the banner for a period before and after the day.",
"author": "Nick Freear {@nfreear}",
"license": "MIT",
"repository": {
"type": "git",
"url": "https://github.com/nfreear/gaad-widget"
},
"browser": "build/GAAD.widget.js",
"keywords": [ "accessibility", "a11y", "browser-widget", "date", "datejs", "icalendar", "event", "day", "international", "GAAD" ],
"author": "Nick Freear {@nfreear}",
"repository": "https://github.com/nfreear/gaad-widget",
"bugs": "https://github.com/nfreear/gaad-widget/issues",
"homepage": "http://nick.freear.org.uk/2017/05/14/gaad-widget.html?utm_source=npm",
"dependencies": {
"datejs": "^1.0.0-rc3",
"icalendar": "^0.7.1"
},
"devDependencies": {
"csslint": "^1.0.5",
"jsonlint": "^1.6.2",
"nice-package": "^3.0.3",
"revalidator": "^0.3.1",
"semistandard": "^11.0.0",
"uglify-js": "^2.8.26"
},
......@@ -25,10 +29,11 @@
},
"scripts": {
"install-legacy-datejs": "mkdir x_legacy; npm i --prefix x_legacy https://github.com/datejs/Datejs#8164739566",
"build": "node_modules/.bin/uglifyjs src/c*.js x_legacy/node_modules/Datejs/build/date.js src/w*.js --comments=/^[!*]/ -bo build/GAAD.widget.js",
"x-build-sa": "node_modules/.bin/uglifyjs src/c*.js node_modules/superagent/superagent.js src/w*.js --comments=/^[!*]/ -bo build/GAAD.sa.js",
"build-min": "node_modules/.bin/uglifyjs build/*.widget.js --comments=/^[!*]/ -mco build/GAAD.widget.min.js",
"test": "node_modules/.bin/semistandard; node_modules/.bin/csslint style"
"build": "uglifyjs src/c*.js x_legacy/node_modules/Datejs/build/date.js src/w*c.js --comments=/^[!*]/ -bo build/GAAD.widget.js",
"x-build-sa": "uglifyjs src/c*.js node_modules/superagent/superagent.js src/w*.js --comments=/^[!*]/ -bo build/GAAD.sa.js",
"build-min": "uglifyjs build/*.widget.js --comments=/^[!*]/ -mco build/GAAD.widget.min.js",
"test": "semistandard && csslint style && jsonlint -q **/*.json",
"x-test": "npm test && node bin/nice.js && node bin/lintl.js"
},
"semistandard": {
"ignore": "build/"
......
/*!
GAAD.widget.js | ©2017 Nick Freear | License: MIT | This is not an official widget!
GAAD.widget.js | ©2017 Nick Freear | License: MIT | NOT an official widget!
https://github.com/nfreear/gaad-widget
http://globalaccessibilityawarenessday.org/
http://globalaccessibilityawarenessday.org
*/
/*!
GAAD.widget.js | ©Nick Freear 2017-04-27 | License: MIT.
https://github.com/nfreear/gaad-widget
*/
(function (W, D, location, console, Date) {
......@@ -18,7 +16,7 @@
var defaults = {
id: 'id-gaad',
script: 'GAAD.widget.', // .js OR .min.js;
script: 'GAAD.widget.', // '.js' OR '.min.js';
lang: 'en',
dir: 'ltr',
texts: {
......@@ -157,10 +155,6 @@
styleEl.type = 'text/css';
styleEl.href = url;
/* var styleEl = D.createElement('style');
styleEl.id = gaad.id + '-css';
styleEl.innerText = gaad.css.join('\n'); */
D.head.appendChild(styleEl);
}
})(window, window.document, window.location, window.console, window.Date);
......@@ -7,9 +7,6 @@
<div id="id-gaad"></div>
<script data-CDN-src="https://cdn.rawgit.com/nfreear/gaad-widget/2.0-beta/build/GAAD.widget.js"></script>
<script src="../build/GAAD.widget.js" data-gaad='{ "debug": true, "X-lang": "fr", "X-theme": "black" }'></script>
......@@ -20,6 +17,6 @@
GAAD.widget.js | © 2017 Nick Freear | License: MIT.
* https://github.com/nfreear/gaad-widget
* http://www.globalaccessibilityawarenessday.org
* http://globalaccessibilityawarenessday.org
</pre>