Skip to content

Commit

Permalink
Reorganized lib, docs and demo
Browse files Browse the repository at this point in the history
  • Loading branch information
benjamindavid committed Jan 20, 2019
1 parent 3260e50 commit e85d702
Show file tree
Hide file tree
Showing 38 changed files with 2,903 additions and 3,315 deletions.
2 changes: 1 addition & 1 deletion build/bili.config.js → bili.config.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
module.exports = {
input: './src/lib.js',
input: './src/index.js',
moduleName: 'CraftUi',
exports: 'named',
format: 'umd,es,cjs,umd-min',
Expand Down
1 change: 1 addition & 0 deletions demo/dist/css/app.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

File renamed without changes.
2 changes: 2 additions & 0 deletions demo/dist/js/app.js

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions demo/dist/js/app.js.map

Large diffs are not rendered by default.

File renamed without changes.
File renamed without changes.
4 changes: 2 additions & 2 deletions src/demo.js → demo/src/index.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import Vue from 'vue'
import App from './App.vue'
import './components'
import App from '../../src/App.vue'
import '../../src/components'

Vue.config.productionTip = false

Expand Down
2 changes: 1 addition & 1 deletion vue.config.js → demo/vue.config.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module.exports = {
filenameHashing: false,
outputDir: 'dist-demo'
outputDir: 'demo/dist/'
}
1 change: 0 additions & 1 deletion dist-demo/css/app.css

This file was deleted.

2 changes: 0 additions & 2 deletions dist-demo/js/app.js

This file was deleted.

1 change: 0 additions & 1 deletion dist-demo/js/app.js.map

This file was deleted.

File renamed without changes.
6 changes: 3 additions & 3 deletions config/storybook/config.js → docs/config/config.js
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
/* Craft UI */
import Vue from 'vue'
import '../../src/sass/storybook.scss';
import CraftUi from '../../src/lib'
import '../src/sass/storybook.scss';
import CraftUi from '../../src/index'
Vue.use(CraftUi)

/* Stories */

/* eslint-disable import/no-extraneous-dependencies */
import { configure } from '@storybook/vue'

const req = require.context('../../src/stories', true, /.stories.js$/)
const req = require.context('../src/stories', true, /.stories.js$/)

function loadStories() {
req.keys().forEach(filename => req(filename))
Expand Down
1 change: 1 addition & 0 deletions docs/dist/css/iframe.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file added docs/dist/favicon.ico
Binary file not shown.
127 changes: 127 additions & 0 deletions docs/dist/iframe.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,127 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta content="IE=edge" http-equiv="X-UA-Compatible" />
<title>Storybook</title>
<link rel="shortcut icon" href="favicon.ico?v=1" />




<base target="_parent">

<style>
:not(.sb-show-main) > .sb-main,
:not(.sb-show-nopreview) > .sb-nopreview,
:not(.sb-show-errordisplay) > .sb-errordisplay {
display: none;
}

.sb-wrapper {
position: fixed;
top: 0;
bottom: 0;
left: 0;
right: 0;
padding: 20px;
font-family: -apple-system, ".SFNSText-Regular", "San Francisco", Roboto, "Segoe UI", "Helvetica Neue", "Lucida Grande", sans-serif;
-webkit-font-smoothing: antialiased;
}

.sb-heading {
font-size: 20px;
font-weight: 600;
letter-spacing: 0.2px;
margin: 10px 0;
}

.sb-nopreview {
display: flex;
align-content: center;
justify-content: center;
}

.sb-nopreview_main {
margin: auto;
padding: 30px;
border-radius: 10px;
background: rgba(0,0,0,0.03);
}

.sb-nopreview_heading {
text-align: center;
}

.sb-errordisplay {
background-color: rgb(187, 49, 49);
color: #FFF;
}

.sb-errordisplay_code {
font-size: 14px;
width: 100vw;
overflow: auto;
}
</style>

<script>
if (window.parent !== window) {
window.__REACT_DEVTOOLS_GLOBAL_HOOK__ = window.parent.__REACT_DEVTOOLS_GLOBAL_HOOK__;
window.__VUE_DEVTOOLS_GLOBAL_HOOK__ = window.parent.__VUE_DEVTOOLS_GLOBAL_HOOK__;
}
</script>



</head>
<body>




<div class="sb-nopreview sb-wrapper">
<div class="sb-nopreview_main">
<h1 class="sb-nopreview_heading sb-heading">No Preview</h1>
<p>Sorry, but you either have no stories or none are selected somehow.</p>
<ul>
<li>Please check the storybook config.</li>
<li>Try reloading the page.</li>
</ul>
</div>
</div>

<div class="sb-errordisplay sb-wrapper">
<div id="error-message" class="sb-heading"></div>
<pre class="sb-errordisplay_code">
<code id="error-stack"></code>
</pre>
</div>



<div id="root"></div>







<script src="static/runtime~iframe.4136dd4de909ebfe31d3.bundle.js" defer></script>



<script src="static/vendors~iframe.6fd72784cbfb82dfd99a.bundle.js" defer></script>



<script src="css/iframe.css" defer></script>

<script src="static/iframe.14a3f1aaf1b44df28654.bundle.js" defer></script>



</body>
</html>
56 changes: 56 additions & 0 deletions docs/dist/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta content="IE=edge" http-equiv="X-UA-Compatible" />
<title>Storybook</title>
<link rel="shortcut icon" href="favicon.ico?v=1" />




<style>
html, body {
overflow: hidden;
height: 100%;
width: 100%;
margin: 0;
padding: 0;
}
</style>

<script>
if (window.parent !== window) {
window.__REACT_DEVTOOLS_GLOBAL_HOOK__ = window.parent.__REACT_DEVTOOLS_GLOBAL_HOOK__;
window.__VUE_DEVTOOLS_GLOBAL_HOOK__ = window.parent.__VUE_DEVTOOLS_GLOBAL_HOOK__;
}
</script>



</head>
<body>





<div id="root"></div>







<script src="static/runtime~manager.02449b205032653e57d0.bundle.js" defer></script>



<script src="static/manager.72fcc7d12dcee244f187.bundle.js" defer></script>



</body>
</html>
34 changes: 34 additions & 0 deletions docs/dist/mini-css-extract-plugin.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta content="IE=edge" http-equiv="X-UA-Compatible" />
<title>Storybook</title>
<link rel="shortcut icon" href="favicon.ico?v=1" />





</head>
<body>





<div id="root"></div>







<script src="../*" defer></script>



</body>
</html>
2 changes: 2 additions & 0 deletions docs/dist/static/iframe.14a3f1aaf1b44df28654.bundle.js

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions docs/dist/static/iframe.14a3f1aaf1b44df28654.bundle.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

101 changes: 101 additions & 0 deletions docs/dist/static/manager.72fcc7d12dcee244f187.bundle.js

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit e85d702

Please sign in to comment.