1
0
mirror of https://github.com/nostalgic-css/NES.css.git synced 2025-08-24 14:52:54 +02:00

docs: remove demo directory

This commit is contained in:
BcRikko
2019-02-20 22:34:33 +09:00
parent 2ed67b9089
commit bd17c12cac
8 changed files with 84 additions and 1159 deletions

View File

@@ -1,6 +1,6 @@
const sampleCollection = [
{
title: "buttons",
title: 'buttons',
showCode: false,
code: `<a class="nes-btn">Normal</a>
@@ -8,10 +8,10 @@ const sampleCollection = [
<button type="button" class="nes-btn is-success">Success</button>
<button type="button" class="nes-btn is-warning">Warning</button>
<button type="button" class="nes-btn is-error">Error</button>
<button type="button" class="nes-btn is-disabled">Disabled</button>`
<button type="button" class="nes-btn is-disabled">Disabled</button>`,
},
{
title: "radios",
title: 'radios',
showCode: false,
code: `<label>
<input type="radio" class="nes-radio" name="answer" checked />
@@ -21,10 +21,10 @@ const sampleCollection = [
<label>
<input type="radio" class="nes-radio" name="answer" />
<span>No</span>
</label>`
</label>`,
},
{
title: "checkboxes",
title: 'checkboxes',
showCode: false,
code: `<label>
<input type="checkbox" class="nes-checkbox" checked />
@@ -36,10 +36,10 @@ const sampleCollection = [
<input type="checkbox" class="nes-checkbox is-dark" checked />
<span>Dark</span>
</label>
</div>`
</div>`,
},
{
title: "Inputs",
title: 'Inputs',
showCode: false,
code: `<div class="nes-field">
<label for="name_field">Your name</label>
@@ -59,16 +59,16 @@ const sampleCollection = [
<div class="nes-field is-inline">
<label for="error_field">.input.is-error</label>
<input type="text" id="error_field" class="nes-input is-error" placeholder="awesome.css">
</div>`
</div>`,
},
{
title: "Textarea",
title: 'Textarea',
showCode: false,
code: `<label for="textarea_field">Textarea</label>
<textarea id="textarea_field" class="nes-textarea"></textarea>`
<textarea id="textarea_field" class="nes-textarea"></textarea>`,
},
{
title: "Selects",
title: 'Selects',
showCode: false,
code: `<div class="nes-select">
<select required>
@@ -100,10 +100,10 @@ const sampleCollection = [
<option value="0">To be</option>
<option value="1">Not to be</option>
</select>
</div>`
</div>`,
},
{
title: "containers",
title: 'containers',
showCode: false,
code: `<div class="nes-container with-title is-centered">
<p class="title">Container.is-centered</p>
@@ -121,97 +121,124 @@ const sampleCollection = [
<div class="nes-container is-rounded is-dark">
<p>Good morning. Thou hast had a good night's sleep, I hope.</p>
</div>`
}
</div>`,
},
];
const coreteam = [
{
name: "B.C.Rikko",
feat: "Creator of NES.css",
github: "BcRikko",
twitter: "bc_rikko"
name: 'B.C.Rikko',
feat: 'Creator of NES.css',
github: 'BcRikko',
twitter: 'bc_rikko',
},
{
name: "Igor Guastalla",
feat: "Create icons",
github: "guastallaigor",
twitter: "guastallaigor"
}
name: 'Igor Guastalla',
feat: 'Create icons',
github: 'guastallaigor',
twitter: 'guastallaigor',
},
];
const emeriti = [
{
name: "Trezy",
feat: "Setup DevOps",
github: "trezy",
twitter: "TrezyCodes"
name: 'Trezy',
feat: 'Setup DevOps',
github: 'trezy',
twitter: 'TrezyCodes',
},
{
name: "Abdullah Samman",
feat: "Setup test suite",
github: "evexoio",
twitter: "evexoio"
}
name: 'Abdullah Samman',
feat: 'Setup test suite',
github: 'evexoio',
twitter: 'evexoio',
},
];
// curl https://api.github.com/repos/nostalgic-css/NES.css/contributors | jq '.[].login'
const contributors = [ "4k1k0", "sombreroEnPuntas", "Divoolej", "soph-iest", "montezume", "sazzadsazib", "KeevanDance", "jdvivar", "IngwiePhoenix", "jjspace", "Baldomo", "DanSnow", "ernestomancebo", "Ilyeo", "Kartones", "rrj-dev", "vicainelli", "stewartrule", "kenshinji", "youngkaneda", "Takumi0901", "loo41", "alexgleason", "agarzola", "fleeting", "JamesIves"];
const contributors = [
'4k1k0',
'sombreroEnPuntas',
'Divoolej',
'soph-iest',
'montezume',
'sazzadsazib',
'KeevanDance',
'jdvivar',
'IngwiePhoenix',
'jjspace',
'Baldomo',
'DanSnow',
'ernestomancebo',
'Ilyeo',
'Kartones',
'rrj-dev',
'vicainelli',
'stewartrule',
'kenshinji',
'youngkaneda',
'Takumi0901',
'loo41',
'alexgleason',
'agarzola',
'fleeting',
'JamesIves',
];
const articles = [
{
icon: 'medium',
title: 'Why I created and released NES.css',
url: 'https://medium.com/@bc_rikko/why-i-created-and-released-nes-css-ee8966bacd09'
url: 'https://medium.com/@bc_rikko/why-i-created-and-released-nes-css-ee8966bacd09',
},
{
icon: 'github',
title: 'Release Radar · December 2018 | The GitHub Blog',
url: 'https://github.blog/2019-01-20-release-radar-december-2018/#nes-css-1-0'
}
]
url: 'https://github.blog/2019-01-20-release-radar-december-2018/#nes-css-1-0',
},
];
new Vue({
el: "#nescss",
data: function() {
el: '#nescss',
data() {
return {
collection: sampleCollection,
coreteam: coreteam,
emeriti: emeriti,
contributors: contributors,
articles: articles,
animateOctocat: false
coreteam,
emeriti,
contributors,
articles,
animateOctocat: false,
};
},
filters: {
capitalize: function(val) {
if (!val) return "";
capitalize(val) {
if (!val) return '';
val = val.toString();
return val.charAt(0).toUpperCase() + val.slice(1);
}
},
},
mounted() {
hljs.initHighlightingOnLoad();
},
methods: {
copy(id) {
const fake = document.createElement("textarea");
const fake = document.createElement('textarea');
fake.value = this.collection.find(a => a.title === id).code;
fake.setAttribute("readonly", "");
fake.setAttribute('readonly', '');
Object.assign(fake.style, {
position: "absolute",
left: "-9999px"
position: 'absolute',
left: '-9999px',
});
this.$el.appendChild(fake);
fake.select();
document.execCommand("copy");
document.execCommand('copy');
this.$el.removeChild(fake);
},
startAnimate() {
this.animateOctocat = true;
},
stopAnimate() {
this.animateOctocat = false
}
}
this.animateOctocat = false;
},
},
});