\n ),\n threshold: 10240,\n minRatio: 0.8\n })\n )\n}\n\nif (config.build.bundleAnalyzerReport) {\n const BundleAnalyzerPlugin = require('webpack-bundle-analyzer').BundleAnalyzerPlugin\n webpackConfig.plugins.push(new BundleAnalyzerPlugin())\n}\n\nmodule.exports = webpackConfig\n","id":"fd2c661b-afd2-4dbd-8a1c-8d678ebdfbcb","is_binary":false,"title":"webpack.prod.conf.js","sha":null,"inserted_at":"2018-05-31T12:43:54","updated_at":"2018-05-31T12:43:54","upload_id":null,"shortid":"Hy4xL9Tw6Jm","source_id":"33dd516a-4865-4483-8f45-a12ee8e866ec","directory_shortid":"SkeLqpDakQ"},{"code":"\u002F\u002F The Vue build version to load with the `import` command\n\u002F\u002F (runtime-only or standalone) has been set in webpack.base.conf with an alias.\nimport Vue from \"vue\";\nimport App from \".\u002FApp\";\nimport store from \".\u002Fstore\";\n\nVue.config.productionTip = false;\n\n\u002F* eslint-disable no-new *\u002F\nnew Vue({\n el: \"#app\",\n store,\n components: { App },\n template: \"\u003CApp\u002F\u003E\"\n});\n","id":"783ad197-6903-4dd8-940e-d1dcd9d9f005","is_binary":false,"title":"main.js","sha":null,"inserted_at":"2018-05-31T12:43:54","updated_at":"2018-05-31T12:43:54","upload_id":null,"shortid":"SJRg89TDpyX","source_id":"33dd516a-4865-4483-8f45-a12ee8e866ec","directory_shortid":"rkGUcavak7"},{"code":"\u003Ctemplate\u003E\n \u003Cdiv id=\"app\"\u003E\n \u003CEditor \u002F\u003E\n \u003CPreview\u002F\u003E\n \u003C\u002Fdiv\u003E\n\u003C\u002Ftemplate\u003E\n\n\u003Cscript\u003E\nimport Preview from \".\u002Fcomponents\u002FPreview\";\nimport Editor from \".\u002Fcomponents\u002FEditor\";\n\nexport default {\n name: \"App\",\n components: {\n Preview,\n Editor\n }\n};\n\u003C\u002Fscript\u003E\n\n\u003Cstyle\u003E\nbody {\n padding: 0;\n margin: 0;\n}\n#app {\n font-family: \"Avenir\", Helvetica, Arial, sans-serif;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n color: #2c3e50;\n margin: 10px;\n}\ntextarea {\n width: 100%;\n margin: 0 auto;\n display: block;\n}\n\u003C\u002Fstyle\u003E\n","id":"a0a55618-2dea-4281-95c3-6d8ba30d3983","is_binary":false,"title":"App.vue","sha":null,"inserted_at":"2018-05-31T12:43:54","updated_at":"2018-05-31T12:43:54","upload_id":null,"shortid":"S1ogLq6PaJQ","source_id":"33dd516a-4865-4483-8f45-a12ee8e866ec","directory_shortid":"rkGUcavak7"},{"code":"'use strict'\nconst merge = require('webpack-merge')\nconst devEnv = require('.\u002Fdev.env')\n\nmodule.exports = merge(devEnv, {\n NODE_ENV: '\"testing\"'\n})\n","id":"80f42c20-5330-416a-bad4-86e93a40f90d","is_binary":false,"title":"test.env.js","sha":null,"inserted_at":"2018-05-31T12:43:54","updated_at":"2018-05-31T12:43:54","upload_id":null,"shortid":"BkOlUcpvaJX","source_id":"33dd516a-4865-4483-8f45-a12ee8e866ec","directory_shortid":"BJZU5avaJX"},{"code":"'use strict'\nmodule.exports = {\n NODE_ENV: '\"production\"'\n}\n","id":"c84e703c-61d0-4b0d-92a3-a4b95832137e","is_binary":false,"title":"prod.env.js","sha":null,"inserted_at":"2018-05-31T12:43:54","updated_at":"2018-05-31T12:43:54","upload_id":null,"shortid":"rJPgI9pw6Jm","source_id":"33dd516a-4865-4483-8f45-a12ee8e866ec","directory_shortid":"BJZU5avaJX"},{"code":"'use strict'\n\u002F\u002F Template version: 1.3.1\n\u002F\u002F see http:\u002F\u002Fvuejs-templates.github.io\u002Fwebpack for documentation.\n\nconst path = require('path')\n\nmodule.exports = {\n dev: {\n\n \u002F\u002F Paths\n assetsSubDirectory: 'static',\n assetsPublicPath: '\u002F',\n proxyTable: {},\n\n \u002F\u002F Various Dev Server settings\n host: 'localhost', \u002F\u002F can be overwritten by process.env.HOST\n port: 8080, \u002F\u002F can be overwritten by process.env.PORT, if port is in use, a free one will be determined\n autoOpenBrowser: false,\n errorOverlay: true,\n notifyOnErrors: true,\n poll: false, \u002F\u002F https:\u002F\u002Fwebpack.js.org\u002Fconfiguration\u002Fdev-server\u002F#devserver-watchoptions-\n\n \u002F\u002F Use Eslint Loader?\n \u002F\u002F If true, your code will be linted during bundling and\n \u002F\u002F linting errors and warnings will be shown in the console.\n useEslint: true,\n \u002F\u002F If true, eslint errors and warnings will also be shown in the error overlay\n \u002F\u002F in the browser.\n showEslintErrorsInOverlay: false,\n\n \u002F**\n * Source Maps\n *\u002F\n\n \u002F\u002F https:\u002F\u002Fwebpack.js.org\u002Fconfiguration\u002Fdevtool\u002F#development\n devtool: 'cheap-module-eval-source-map',\n\n \u002F\u002F If you have problems debugging vue-files in devtools,\n \u002F\u002F set this to false - it *may* help\n \u002F\u002F https:\u002F\u002Fvue-loader.vuejs.org\u002Fen\u002Foptions.html#cachebusting\n cacheBusting: true,\n\n cssSourceMap: true\n },\n\n build: {\n \u002F\u002F Template for index.html\n index: path.resolve(__dirname, '..\u002Fdist\u002Findex.html'),\n\n \u002F\u002F Paths\n assetsRoot: path.resolve(__dirname, '..\u002Fdist'),\n assetsSubDirectory: 'static',\n assetsPublicPath: '\u002F',\n\n \u002F**\n * Source Maps\n *\u002F\n\n productionSourceMap: true,\n \u002F\u002F https:\u002F\u002Fwebpack.js.org\u002Fconfiguration\u002Fdevtool\u002F#production\n devtool: '#source-map',\n\n \u002F\u002F Gzip off by default as many popular static hosts such as\n \u002F\u002F Surge or Netlify already gzip all static assets for you.\n \u002F\u002F Before setting to `true`, make sure to:\n \u002F\u002F npm install --save-dev compression-webpack-plugin\n productionGzip: false,\n productionGzipExtensions: ['js', 'css'],\n\n \u002F\u002F Run the build command with an extra argument to\n \u002F\u002F View the bundle analyzer report after build finishes:\n \u002F\u002F `npm run build --report`\n \u002F\u002F Set to `true` or `false` to always turn it on or off\n bundleAnalyzerReport: process.env.npm_config_report\n }\n}\n","id":"77242eb7-527f-4ec9-83df-0cbb1b817c16","is_binary":false,"title":"index.js","sha":null,"inserted_at":"2018-05-31T12:43:54","updated_at":"2018-05-31T12:43:54","upload_id":null,"shortid":"ryUxLq6w61Q","source_id":"33dd516a-4865-4483-8f45-a12ee8e866ec","directory_shortid":"BJZU5avaJX"},{"code":"\u003Ctemplate\u003E\n \u003Cdiv id=\"result\"\u003E\n \u003Csection id=\"source\"\u003E\n \u003Ch1\u003ESource\u003C\u002Fh1\u003E\n \u003Ctextarea v-model=\"source\" cols=\"30\" rows=\"10\" class=\"output-body\" readonly\u003E\u003C\u002Ftextarea\u003E\n \u003C\u002Fsection\u003E\n\n \u003Csection id=\"preview\"\u003E\n \u003Ch1\u003EPreview\u003C\u002Fh1\u003E\n \u003Cdiv v-html=\"preview\" class=\"preview-body\"\u003E\u003C\u002Fdiv\u003E\n \u003C\u002Fsection\u003E\n \u003C\u002Fdiv\u003E\n\u003C\u002Ftemplate\u003E\n\n\u003Cscript\u003E\nimport { mapState } from \"vuex\";\n\nexport default {\n name: \"Preview\",\n\n computed: {\n ...mapState([\"preview\", \"source\"])\n }\n};\n\u003C\u002Fscript\u003E\n\n\u003Cstyle scoped\u003E\n.preview-body {\n color: #764;\n box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);\n border-radius: 10px;\n padding: 20px;\n}\n\n.preview-body p {\n margin-top: 24px;\n}\n\n.preview-body img {\n display: block;\n width: 100%;\n height: auto;\n border-radius: 10px;\n margin: 16px auto;\n}\n\n.preview-body ul,\n.preview-body ol {\n margin: 0 24px 24px;\n}\n\n.preview-body ul {\n list-style-type: disc;\n}\n\n.preview-body strong {\n font-weight: bold;\n color: #f66;\n}\n\n.preview-body em {\n font-style: normal;\n background: none;\n color: #0cc;\n}\n\n.preview-body b {\n font-weight: bold;\n}\n\n.preview-body a {\n border-bottom: solid 1px;\n color: #5bf;\n}\n\u003C\u002Fstyle\u003E\n","id":"de9c0ee3-8ac7-4df4-93ba-bd16ea7971f8","is_binary":false,"title":"Preview.vue","sha":null,"inserted_at":"2018-05-31T12:43:54","updated_at":"2018-05-31T12:58:15","upload_id":null,"shortid":"rkTeL96v6km","source_id":"33dd516a-4865-4483-8f45-a12ee8e866ec","directory_shortid":"HJQI5TwTy7"},{"code":"'use strict'\nconst utils = require('.\u002Futils')\nconst webpack = require('webpack')\nconst config = require('..\u002Fconfig')\nconst merge = require('webpack-merge')\nconst path = require('path')\nconst baseWebpackConfig = require('.\u002Fwebpack.base.conf')\nconst CopyWebpackPlugin = require('copy-webpack-plugin')\nconst HtmlWebpackPlugin = require('html-webpack-plugin')\nconst FriendlyErrorsPlugin = require('friendly-errors-webpack-plugin')\nconst portfinder = require('portfinder')\n\nconst HOST = process.env.HOST\nconst PORT = process.env.PORT && Number(process.env.PORT)\n\nconst devWebpackConfig = merge(baseWebpackConfig, {\n module: {\n rules: utils.styleLoaders({ sourceMap: config.dev.cssSourceMap, usePostCSS: true })\n },\n \u002F\u002F cheap-module-eval-source-map is faster for development\n devtool: config.dev.devtool,\n\n \u002F\u002F these devServer options should be customized in \u002Fconfig\u002Findex.js\n devServer: {\n clientLogLevel: 'warning',\n historyApiFallback: {\n rewrites: [\n { from: \u002F.*\u002F, to: path.posix.join(config.dev.assetsPublicPath, 'index.html') },\n ],\n },\n hot: true,\n contentBase: false, \u002F\u002F since we use CopyWebpackPlugin.\n compress: true,\n host: HOST || config.dev.host,\n port: PORT || config.dev.port,\n open: config.dev.autoOpenBrowser,\n overlay: config.dev.errorOverlay\n ? { warnings: false, errors: true }\n : false,\n publicPath: config.dev.assetsPublicPath,\n proxy: config.dev.proxyTable,\n quiet: true, \u002F\u002F necessary for FriendlyErrorsPlugin\n watchOptions: {\n poll: config.dev.poll,\n }\n },\n plugins: [\n new webpack.DefinePlugin({\n 'process.env': require('..\u002Fconfig\u002Fdev.env')\n }),\n new webpack.HotModuleReplacementPlugin(),\n new webpack.NamedModulesPlugin(), \u002F\u002F HMR shows correct file names in console on update.\n new webpack.NoEmitOnErrorsPlugin(),\n \u002F\u002F https:\u002F\u002Fgithub.com\u002Fampedandwired\u002Fhtml-webpack-plugin\n new HtmlWebpackPlugin({\n filename: 'index.html',\n template: 'index.html',\n inject: true\n }),\n \u002F\u002F copy custom static assets\n new CopyWebpackPlugin([\n {\n from: path.resolve(__dirname, '..\u002Fstatic'),\n to: config.dev.assetsSubDirectory,\n ignore: ['.*']\n }\n ])\n ]\n})\n\nmodule.exports = new Promise((resolve, reject) =\u003E {\n portfinder.basePort = process.env.PORT || config.dev.port\n portfinder.getPort((err, port) =\u003E {\n if (err) {\n reject(err)\n } else {\n \u002F\u002F publish the new Port, necessary for e2e tests\n process.env.PORT = port\n \u002F\u002F add port to devServer config\n devWebpackConfig.devServer.port = port\n\n \u002F\u002F Add FriendlyErrorsPlugin\n devWebpackConfig.plugins.push(new FriendlyErrorsPlugin({\n compilationSuccessInfo: {\n messages: [`Your application is running here: http:\u002F\u002F${devWebpackConfig.devServer.host}:${port}`],\n },\n onErrors: config.dev.notifyOnErrors\n ? utils.createNotifierCallback()\n : undefined\n }))\n\n resolve(devWebpackConfig)\n }\n })\n})\n","id":"7f36f6aa-d18a-4f90-8c11-b2f6b5954b74","is_binary":false,"title":"webpack.dev.conf.js","sha":null,"inserted_at":"2018-05-31T12:43:54","updated_at":"2018-05-31T12:43:54","upload_id":null,"shortid":"Sy7x856wpk7","source_id":"33dd516a-4865-4483-8f45-a12ee8e866ec","directory_shortid":"SkeLqpDakQ"},{"code":"'use strict'\nconst path = require('path')\nconst utils = require('.\u002Futils')\nconst config = require('..\u002Fconfig')\nconst vueLoaderConfig = require('.\u002Fvue-loader.conf')\n\nfunction resolve (dir) {\n return path.join(__dirname, '..', dir)\n}\n\nconst createLintingRule = () =\u003E ({\n test: \u002F\\.(js|vue)$\u002F,\n loader: 'eslint-loader',\n enforce: 'pre',\n include: [resolve('src'), resolve('test')],\n options: {\n formatter: require('eslint-friendly-formatter'),\n emitWarning: !config.dev.showEslintErrorsInOverlay\n }\n})\n\nmodule.exports = {\n context: path.resolve(__dirname, '..\u002F'),\n entry: {\n app: '.\u002Fsrc\u002Fmain.js'\n },\n output: {\n path: config.build.assetsRoot,\n filename: '[name].js',\n publicPath: process.env.NODE_ENV === 'production'\n ? config.build.assetsPublicPath\n : config.dev.assetsPublicPath\n },\n resolve: {\n extensions: ['.js', '.vue', '.json'],\n alias: {\n 'vue
: 'vue\u002Fdist\u002Fvue.esm.js',\n '@': resolve('src'),\n }\n },\n module: {\n rules: [\n ...(config.dev.useEslint ? [createLintingRule()] : []),\n {\n test: \u002F\\.vue$\u002F,\n loader: 'vue-loader',\n options: vueLoaderConfig\n },\n {\n test: \u002F\\.js$\u002F,\n loader: 'babel-loader',\n include: [resolve('src'), resolve('test'), resolve('node_modules\u002Fwebpack-dev-server\u002Fclient')]\n },\n {\n test: \u002F\\.(png|jpe?g|gif|svg)(\\?.*)?$\u002F,\n loader: 'url-loader',\n options: {\n limit: 10000,\n name: utils.assetsPath('img\u002F[name].[hash:7].[ext]')\n }\n },\n {\n test: \u002F\\.(mp4|webm|ogg|mp3|wav|flac|aac)(\\?.*)?$\u002F,\n loader: 'url-loader',\n options: {\n limit: 10000,\n name: utils.assetsPath('media\u002F[name].[hash:7].[ext]')\n }\n },\n {\n test: \u002F\\.(woff2?|eot|ttf|otf)(\\?.*)?$\u002F,\n loader: 'url-loader',\n options: {\n limit: 10000,\n name: utils.assetsPath('fonts\u002F[name].[hash:7].[ext]')\n }\n }\n ]\n },\n node: {\n \u002F\u002F prevent webpack from injecting useless setImmediate polyfill because Vue\n \u002F\u002F source contains it (although only uses it if it's native).\n setImmediate: false,\n \u002F\u002F prevent webpack from injecting mocks to Node native modules\n \u002F\u002F that does not make sense for the client\n dgram: 'empty',\n fs: 'empty',\n net: 'empty',\n tls: 'empty',\n child_process: 'empty'\n }\n}\n","id":"e942ea1c-1202-44de-bb6e-1de606396a63","is_binary":false,"title":"webpack.base.conf.js","sha":null,"inserted_at":"2018-05-31T12:43:54","updated_at":"2018-05-31T12:43:54","upload_id":null,"shortid":"H1GlIcawpym","source_id":"33dd516a-4865-4483-8f45-a12ee8e866ec","directory_shortid":"SkeLqpDakQ"},{"code":"'use strict'\nconst utils = require('.\u002Futils')\nconst config = require('..\u002Fconfig')\nconst isProduction = process.env.NODE_ENV === 'production'\nconst sourceMapEnabled = isProduction\n ? config.build.productionSourceMap\n : config.dev.cssSourceMap\n\nmodule.exports = {\n loaders: utils.cssLoaders({\n sourceMap: sourceMapEnabled,\n extract: isProduction\n }),\n cssSourceMap: sourceMapEnabled,\n cacheBusting: config.dev.cacheBusting,\n transformToRequire: {\n video: ['src', 'poster'],\n source: 'src',\n img: 'src',\n image: 'xlink:href'\n }\n}\n","id":"219e188a-8125-4fb5-b648-3a2ae054c57e","is_binary":false,"title":"vue-loader.conf.js","sha":null,"inserted_at":"2018-05-31T12:43:54","updated_at":"2018-05-31T12:43:54","upload_id":null,"shortid":"BJWe89aD6JQ","source_id":"33dd516a-4865-4483-8f45-a12ee8e866ec","directory_shortid":"SkeLqpDakQ"},{"code":"'use strict'\nconst path = require('path')\nconst config = require('..\u002Fconfig')\nconst ExtractTextPlugin = require('extract-text-webpack-plugin')\nconst packageConfig = require('..\u002Fpackage.json')\n\nexports.assetsPath = function (_path) {\n const assetsSubDirectory = process.env.NODE_ENV === 'production'\n ? config.build.assetsSubDirectory\n : config.dev.assetsSubDirectory\n\n return path.posix.join(assetsSubDirectory, _path)\n}\n\nexports.cssLoaders = function (options) {\n options = options || {}\n\n const cssLoader = {\n loader: 'css-loader',\n options: {\n sourceMap: options.sourceMap\n }\n }\n\n const postcssLoader = {\n loader: 'postcss-loader',\n options: {\n sourceMap: options.sourceMap\n }\n }\n\n \u002F\u002F generate loader string to be used with extract text plugin\n function generateLoaders (loader, loaderOptions) {\n const loaders = options.usePostCSS ? [cssLoader, postcssLoader] : [cssLoader]\n\n if (loader) {\n loaders.push({\n loader: loader + '-loader',\n options: Object.assign({}, loaderOptions, {\n sourceMap: options.sourceMap\n })\n })\n }\n\n \u002F\u002F Extract CSS when that option is specified\n \u002F\u002F (which is the case during production build)\n if (options.extract) {\n return ExtractTextPlugin.extract({\n use: loaders,\n fallback: 'vue-style-loader'\n })\n } else {\n return ['vue-style-loader'].concat(loaders)\n }\n }\n\n \u002F\u002F https:\u002F\u002Fvue-loader.vuejs.org\u002Fen\u002Fconfigurations\u002Fextract-css.html\n return {\n css: generateLoaders(),\n postcss: generateLoaders(),\n less: generateLoaders('less'),\n sass: generateLoaders('sass', { indentedSyntax: true }),\n scss: generateLoaders('sass'),\n stylus: generateLoaders('stylus'),\n styl: generateLoaders('stylus')\n }\n}\n\n\u002F\u002F Generate loaders for standalone style files (outside of .vue)\nexports.styleLoaders = function (options) {\n const output = []\n const loaders = exports.cssLoaders(options)\n\n for (const extension in loaders) {\n const loader = loaders[extension]\n output.push({\n test: new RegExp('\\\\.' + extension + '
),\n use: loader\n })\n }\n\n return output\n}\n\nexports.createNotifierCallback = () =\u003E {\n const notifier = require('node-notifier')\n\n return (severity, errors) =\u003E {\n if (severity !== 'error') return\n\n const error = errors[0]\n const filename = error.file && error.file.split('!').pop()\n\n notifier.notify({\n title: packageConfig.name,\n message: severity + ': ' + error.name,\n subtitle: filename || '',\n icon: path.join(__dirname, 'logo.png')\n })\n }\n}\n","id":"aaf3d4a1-35d7-4f7f-821f-1256e660a18e","is_binary":false,"title":"utils.js","sha":null,"inserted_at":"2018-05-31T12:43:54","updated_at":"2018-05-31T12:43:54","upload_id":null,"shortid":"S1xeLqawak7","source_id":"33dd516a-4865-4483-8f45-a12ee8e866ec","directory_shortid":"SkeLqpDakQ"},{"code":"https:\u002F\u002Frawgit.com\u002FTenderfeel\u002Fvue-simple-markup-editor\u002F45faa0e06d94c1f865dcbb83c6d8a67b19587490\u002Fbuild\u002Flogo.png","id":"80382048-3cdd-4810-bd91-e7561269b972","is_binary":true,"title":"logo.png","sha":null,"inserted_at":"2018-05-31T12:43:54","updated_at":"2018-05-31T12:43:54","upload_id":null,"shortid":"ByylUcTD6ym","source_id":"33dd516a-4865-4483-8f45-a12ee8e866ec","directory_shortid":"SkeLqpDakQ"},{"code":"'use strict'\nconst chalk = require('chalk')\nconst semver = require('semver')\nconst packageConfig = require('..\u002Fpackage.json')\nconst shell = require('shelljs')\n\nfunction exec (cmd) {\n return require('child_process').execSync(cmd).toString().trim()\n}\n\nconst versionRequirements = [\n {\n name: 'node',\n currentVersion: semver.clean(process.version),\n versionRequirement: packageConfig.engines.node\n }\n]\n\nif (shell.which('npm')) {\n versionRequirements.push({\n name: 'npm',\n currentVersion: exec('npm --version'),\n versionRequirement: packageConfig.engines.npm\n })\n}\n\nmodule.exports = function () {\n const warnings = []\n\n for (let i = 0; i \u003C versionRequirements.length; i++) {\n const mod = versionRequirements[i]\n\n if (!semver.satisfies(mod.currentVersion, mod.versionRequirement)) {\n warnings.push(mod.name + ': ' +\n chalk.red(mod.currentVersion) + ' should be ' +\n chalk.green(mod.versionRequirement)\n )\n }\n }\n\n if (warnings.length) {\n console.log('')\n console.log(chalk.yellow('To use this template, you must update following to modules:'))\n console.log()\n\n for (let i = 0; i \u003C warnings.length; i++) {\n const warning = warnings[i]\n console.log(' ' + warning)\n }\n\n console.log()\n process.exit(1)\n }\n}\n","id":"098a5e78-ac46-41b2-82a0-3f640bff16dc","is_binary":false,"title":"check-versions.js","sha":null,"inserted_at":"2018-05-31T12:43:54","updated_at":"2018-05-31T12:43:54","upload_id":null,"shortid":"BJCIqaw6yX","source_id":"33dd516a-4865-4483-8f45-a12ee8e866ec","directory_shortid":"SkeLqpDakQ"},{"code":"'use strict'\nrequire('.\u002Fcheck-versions')()\n\nprocess.env.NODE_ENV = 'production'\n\nconst ora = require('ora')\nconst rm = require('rimraf')\nconst path = require('path')\nconst chalk = require('chalk')\nconst webpack = require('webpack')\nconst config = require('..\u002Fconfig')\nconst webpackConfig = require('.\u002Fwebpack.prod.conf')\n\nconst spinner = ora('building for production...')\nspinner.start()\n\nrm(path.join(config.build.assetsRoot, config.build.assetsSubDirectory), err =\u003E {\n if (err) throw err\n webpack(webpackConfig, (err, stats) =\u003E {\n spinner.stop()\n if (err) throw err\n process.stdout.write(stats.toString({\n colors: true,\n modules: false,\n children: false, \u002F\u002F If you are using ts-loader, setting this to true will make TypeScript errors show up during build.\n chunks: false,\n chunkModules: false\n }) + '\\n\\n')\n\n if (stats.hasErrors()) {\n console.log(chalk.red(' Build failed with errors.\\n'))\n process.exit(1)\n }\n\n console.log(chalk.cyan(' Build complete.\\n'))\n console.log(chalk.yellow(\n ' Tip: built files are meant to be served over an HTTP server.\\n' +\n ' Opening index.html over file:\u002F\u002F won\\'t work.\\n'\n ))\n })\n})\n","id":"1696d126-e827-4cff-82d7-8ed45c058b68","is_binary":false,"title":"build.js","sha":null,"inserted_at":"2018-05-31T12:43:54","updated_at":"2018-05-31T12:43:54","upload_id":null,"shortid":"Bk6896DpJQ","source_id":"33dd516a-4865-4483-8f45-a12ee8e866ec","directory_shortid":"SkeLqpDakQ"},{"code":"\u002Fbuild\u002F\n\u002Fconfig\u002F\n\u002Fdist\u002F\n\u002F*.js\n\u002Ftest\u002Funit\u002Fcoverage\u002F\n","id":"22b5fc39-9228-401a-bc15-616335767702","is_binary":false,"title":".eslintignore","sha":null,"inserted_at":"2018-05-31T12:43:54","updated_at":"2018-05-31T12:43:54","upload_id":null,"shortid":"r1dUcTDpJX","source_id":"33dd516a-4865-4483-8f45-a12ee8e866ec","directory_shortid":null},{"code":"root = true\n\n[*]\ncharset = utf-8\nindent_style = space\nindent_size = 2\nend_of_line = lf\ninsert_final_newline = true\ntrim_trailing_whitespace = true\n","id":"f65f2431-12e9-4272-91fd-861971d77592","is_binary":false,"title":".editorconfig","sha":null,"inserted_at":"2018-05-31T12:43:54","updated_at":"2018-05-31T12:43:54","upload_id":null,"shortid":"ryP8caP6yX","source_id":"33dd516a-4865-4483-8f45-a12ee8e866ec","directory_shortid":null},{"code":"{\n \"presets\": [\n [\"env\", {\n \"modules\": false,\n \"targets\": {\n \"browsers\": [\"\u003E 1%\", \"last 2 versions\", \"not ie \u003C= 8\"]\n }\n }],\n \"stage-2\"\n ],\n \"plugins\": [\"transform-vue-jsx\", \"transform-runtime\"],\n \"env\": {\n \"test\": {\n \"presets\": [\"env\", \"stage-2\"],\n \"plugins\": [\"transform-vue-jsx\", \"transform-es2015-modules-commonjs\", \"dynamic-import-node\"]\n }\n }\n}\n","id":"295a74a2-56a0-4a5b-b0dd-03be402c70a5","is_binary":false,"title":".babelrc","sha":null,"inserted_at":"2018-05-31T12:43:54","updated_at":"2018-05-31T12:43:54","upload_id":null,"shortid":"H1ILqTvakQ","source_id":"33dd516a-4865-4483-8f45-a12ee8e866ec","directory_shortid":null},{"code":"\u003Ctemplate\u003E\n \u003Cdiv id=\"editor\"\u003E\n \u003Cdiv id=\"controller\"\u003E\n \u003Cbutton id=\"addImg\" @click=\"togglePrompt('img')\"\u003EImage\u003C\u002Fbutton\u003E\n \u003Cbutton id=\"addLink\" @click=\"togglePrompt('link')\"\u003ELink\u003C\u002Fbutton\u003E\n \u003Clabel\u003E\n quot:\u003Cselect v-model=\"isQuot\"\u003E\n \u003Coption v-for=\"quot in quotations\" :value=\"quot.value\" :key=\"quot.value\"\u003E\n {{quot.text}}\n \u003C\u002Foption\u003E\n \u003C\u002Fselect\u003E\n \u003C\u002Flabel\u003E\n\n \u003Cbutton id=\"addStrong\" @click=\"addStrong\"\u003EStrong\u003C\u002Fbutton\u003E\n \u003Cbutton id=\"addEm\" @click=\"addEm\"\u003Eem\u003C\u002Fbutton\u003E\n \u003Cbutton id=\"addBold\" @click=\"addBold\"\u003EBold\u003C\u002Fbutton\u003E\n \u003Clabel\u003E\n \u003Cinput type=\"checkbox\" v-model=\"isWrapP\" @change=\"update\"\u003Ewrap <p>\n \u003C\u002Flabel\u003E\n \u003Clabel\u003E\n \u003Cinput type=\"checkbox\" v-model=\"isOneLine\" @change=\"update\"\u003Eoneline\n \u003C\u002Flabel\u003E\n\n \u003Cdiv class=\"hide-input\" v-if=\"prompt === 'link'\"\u003E\n \u003Clabel for=\"inputLink\"\u003EURL:\u003C\u002Flabel\u003E\n \u003Cinput type=\"url\" id=\"inputLink\" v-model=\"href\"\u003E\n \u003Clabel\u003E\u003Cinput type=\"checkbox\" v-model=\"targetBlank\"\u003E_blank\u003C\u002Flabel\u003E\n \u003Cbutton class=\"btn-ok\" @click=\"addLink\"\u003EOK\u003C\u002Fbutton\u003E\n \u003C\u002Fdiv\u003E\n\n \u003Cdiv class=\"hide-input\" v-if=\"prompt === 'img'\"\u003E\n \u003Clabel for=\"inputImg\"\u003Eimg src:\u003C\u002Flabel\u003E\n \u003Cinput type=\"url\" id=\"inputImg\" v-model=\"src\"\u003E\n \u003Cbutton class=\"btn-ok\" @click=\"addImg\"\u003EOK\u003C\u002Fbutton\u003E\n \u003C\u002Fdiv\u003E\n \u003C\u002Fdiv\u003E\n\n \u003Ctextarea id=\"body\" v-model=\"body\" cols=\"30\" rows=\"10\" class=\"input-body\" \n @select=\"getSelection\" @click=\"getSelection\"\u003E\n \u003C\u002Ftextarea\u003E\n \u003C\u002Fdiv\u003E\n\u003C\u002Ftemplate\u003E\n\n\u003Cscript\u003E\nimport { mapActions, mapState } from 'vuex'\n\nexport default {\n data() {\n return {\n prompt: null,\n targetBlank: false,\n quotations: [\n { text: 'None', value: 0 },\n { text: 'Single', value: 1 },\n { text: 'Double', value: 2 }\n ],\n src: '',\n href: ''\n }\n },\n computed: {\n ...mapState(['selection']),\n body: {\n get() {\n return this.$store.state.body\n },\n set(value) {\n this.$store.commit('updateBody', value)\n }\n },\n isOneLine: {\n get() {\n return this.$store.state.isOneLine\n },\n set(value) {\n this.$store.commit('updateIsOneLine', value)\n }\n },\n isWrapP: {\n get() {\n return this.$store.state.isWrapP\n },\n set(value) {\n this.$store.commit('updateIsWrapP', value)\n }\n },\n isQuot: {\n get() {\n return this.$store.state.isQuot\n },\n set(value) {\n this.$store.commit('updateIsQuot', value)\n }\n }\n },\n methods: {\n ...mapActions(['getSelection', 'surround', 'update']),\n\n togglePrompt(target) {\n this.prompt = target\n },\n\n getQuot() {\n return this.isQuot === 2 ? '\"' : this.isQuot === 1 ? \"'\" : ''\n },\n\n addImg() {\n this.surround([\n '\u003Cimg src=' +\n this.getQuot() +\n this.src +\n this.getQuot() +\n ' class=' +\n this.getQuot() +\n 'banner' +\n this.getQuot() +\n '\u003E',\n ''\n ])\n },\n\n addLink() {\n let before = '\u003Ca href=' + this.getQuot() + this.href + this.getQuot()\n\n if (this.targetBlank) {\n before += ' target=' + this.getQuot() + '_blank' + this.getQuot()\n }\n this.href = ''\n this.surround([before + '\u003E', '\u003C\u002Fa\u003E'])\n },\n\n addEm() {\n this.surround(['\u003Cem\u003E', '\u003C\u002Fem\u003E'])\n },\n addBold() {\n this.surround(['\u003Cb\u003E', '\u003C\u002Fb\u003E'])\n },\n addStrong() {\n this.surround(['\u003Cstrong\u003E', '\u003C\u002Fstrong\u003E'])\n }\n }\n}\n\u003C\u002Fscript\u003E\n\n\u003Cstyle scoped\u003E\n#controller {\n padding: 10px;\n background: #efefef;\n}\ninput[type='url'] {\n width: 70%;\n max-width: 400px;\n}\n\u003C\u002Fstyle\u003E\n","id":"d82ab0d3-c359-41f4-9387-d359154c1113","is_binary":false,"title":"Editor.vue","sha":null,"inserted_at":"2018-05-31T12:43:54","updated_at":"2018-06-15T02:30:47","upload_id":null,"shortid":"Sk2x85TPa1m","source_id":"33dd516a-4865-4483-8f45-a12ee8e866ec","directory_shortid":"HJQI5TwTy7"},{"code":"import { shallowMount, createLocalVue } from \"@vue\u002Ftest-utils\";\r\nimport Vuex from \"vuex\";\r\nimport Preview from \"@\u002Fcomponents\u002FPreview\";\r\n\r\nconst localVue = createLocalVue();\r\n\r\nlocalVue.use(Vuex);\r\n\r\ndescribe(\"Preview.vue\", () =\u003E {\r\n let actions;\r\n let store;\r\n\r\n beforeEach(() =\u003E {\r\n store = new Vuex.Store({\r\n state: {\r\n preview: \"\u003Cp\u003ETest\u003C\u002Fp\u003E\",\r\n source: \"\u003Cp\u003ETest\u003C\u002Fp\u003E\"\r\n }\r\n });\r\n });\r\n\r\n it(\"render Preview\", () =\u003E {\r\n const wrapper = shallowMount(Preview, {\r\n store,\r\n localVue\r\n });\r\n expect(wrapper.find(\".preview-body\").text()).toBe(\"Test\");\r\n });\r\n});\r\n","id":"f51f944e-8a7d-446e-a28c-2b94dda1dc9c","is_binary":false,"title":"Preview.spec.js","sha":null,"inserted_at":"2019-03-30T09:36:22","updated_at":"2019-03-30T09:56:00","upload_id":null,"shortid":"8ByXm","source_id":"33dd516a-4865-4483-8f45-a12ee8e866ec","directory_shortid":"2QQlj"},{"code":"\u002F\u002F https:\u002F\u002Feslint.org\u002Fdocs\u002Fuser-guide\u002Fconfiguring\n\nmodule.exports = {\n root: true,\n parserOptions: {\n parser: \"babel-eslint\"\n },\n env: {\n browser: true\n },\n \u002F\u002F https:\u002F\u002Fgithub.com\u002Fvuejs\u002Feslint-plugin-vue#priority-a-essential-error-prevention\n \u002F\u002F consider switching to `plugin:vue\u002Fstrongly-recommended` or `plugin:vue\u002Frecommended` for stricter rules.\n extends: [\"plugin:vue\u002Fessential\", \"airbnb-base\"],\n \u002F\u002F required to lint *.vue files\n plugins: [\"vue\", \"jest\"],\n \u002F\u002F check if imports actually resolve\n settings: {\n \"import\u002Fresolver\": {\n webpack: {\n config: \"build\u002Fwebpack.base.conf.js\"\n }\n }\n },\n \u002F\u002F add your custom rules here\n rules: {\n \u002F\u002F don't require .vue extension when importing\n \"import\u002Fextensions\": [\n \"error\",\n \"always\",\n {\n js: \"never\",\n vue: \"never\"\n }\n ],\n \u002F\u002F disallow reassignment of function parameters\n \u002F\u002F disallow parameter object manipulation except for specific exclusions\n \"no-param-reassign\": [\n \"error\",\n {\n props: true,\n ignorePropertyModificationsFor: [\n \"state\", \u002F\u002F for vuex state\n \"acc\", \u002F\u002F for reduce accumulators\n \"e\" \u002F\u002F for e.returnvalue\n ]\n }\n ],\n \u002F\u002F allow optionalDependencies\n \"import\u002Fno-extraneous-dependencies\": [\n \"error\",\n {\n optionalDependencies: [\"test\u002Funit\u002Findex.js\"]\n }\n ],\n \u002F\u002F allow debugger during development\n \"no-debugger\": process.env.NODE_ENV === \"production\" ? \"error\" : \"off\"\n }\n};\n","id":"60b954b1-bcc0-4fb3-b38c-6b650c43d5f2","is_binary":false,"title":".eslintrc.js","sha":null,"inserted_at":"2018-05-31T12:43:54","updated_at":"2019-03-30T09:43:18","upload_id":null,"shortid":"H1FUcpPp17","source_id":"33dd516a-4865-4483-8f45-a12ee8e866ec","directory_shortid":null},{"code":"{\n \"name\": \"vue-simple-markup-editor\",\n \"version\": \"1.0.0\",\n \"description\": \"\",\n \"main\": \"src\u002Fmain.js\",\n \"private\": true,\n \"scripts\": {\n \"dev\": \"webpack-dev-server --inline --progress --config build\u002Fwebpack.dev.conf.js\",\n \"start\": \"npm run dev\",\n \"unit\": \"jest --config test\u002Funit\u002Fjest.conf.js --coverage\",\n \"test\": \"jest\",\n \"lint\": \"eslint --ext .js,.vue src test\u002Funit\",\n \"build\": \"node build\u002Fbuild.js\"\n },\n \"dependencies\": {\n \"@vue\u002Ftest-utils\": \"1.0.0-beta.29\",\n \"babel-jest\": \"24.5.0\",\n \"eslint-plugin-jest\": \"22.4.1\",\n \"jest\": \"24.5.0\",\n \"vue\": \"^2.5.2\",\n \"vue-jest\": \"3.0.4\",\n \"vue-template-compiler\": \"2.6.10\",\n \"vuex\": \"3.0.1\"\n },\n \"devDependencies\": {\n \"autoprefixer\": \"^7.1.2\",\n \"babel-core\": \"^6.22.1\",\n \"babel-eslint\": \"^8.2.1\",\n \"babel-helper-vue-jsx-merge-props\": \"^2.0.3\",\n \"babel-jest\": \"^21.0.2\",\n \"babel-loader\": \"^7.1.1\",\n \"babel-plugin-dynamic-import-node\": \"^1.2.0\",\n \"babel-plugin-syntax-jsx\": \"^6.18.0\",\n \"babel-plugin-transform-es2015-modules-commonjs\": \"^6.26.0\",\n \"babel-plugin-transform-runtime\": \"^6.22.0\",\n \"babel-plugin-transform-vue-jsx\": \"^3.5.0\",\n \"babel-preset-env\": \"^1.3.2\",\n \"babel-preset-stage-2\": \"^6.22.0\",\n \"chalk\": \"^2.0.1\",\n \"copy-webpack-plugin\": \"^4.0.1\",\n \"css-loader\": \"^0.28.0\",\n \"eslint\": \"^4.15.0\",\n \"eslint-config-airbnb-base\": \"^11.3.0\",\n \"eslint-friendly-formatter\": \"^3.0.0\",\n \"eslint-import-resolver-webpack\": \"^0.8.3\",\n \"eslint-loader\": \"^1.7.1\",\n \"eslint-plugin-import\": \"^2.7.0\",\n \"eslint-plugin-vue\": \"^4.0.0\",\n \"extract-text-webpack-plugin\": \"^3.0.0\",\n \"file-loader\": \"^1.1.4\",\n \"friendly-errors-webpack-plugin\": \"^1.6.1\",\n \"html-webpack-plugin\": \"^2.30.1\",\n \"jest\": \"^22.0.4\",\n \"jest-serializer-vue\": \"^0.3.0\",\n \"node-notifier\": \"^5.1.2\",\n \"optimize-css-assets-webpack-plugin\": \"^3.2.0\",\n \"ora\": \"^1.2.0\",\n \"portfinder\": \"^1.0.13\",\n \"postcss-import\": \"^11.0.0\",\n \"postcss-loader\": \"^2.0.8\",\n \"postcss-url\": \"^7.2.1\",\n \"rimraf\": \"^2.6.0\",\n \"semver\": \"^5.3.0\",\n \"shelljs\": \"^0.7.6\",\n \"uglifyjs-webpack-plugin\": \"^1.1.1\",\n \"url-loader\": \"^0.5.8\",\n \"vue-jest\": \"^1.0.2\",\n \"vue-loader\": \"^13.3.0\",\n \"vue-style-loader\": \"^3.0.1\",\n \"vue-template-compiler\": \"^2.5.2\",\n \"webpack\": \"^3.6.0\",\n \"webpack-bundle-analyzer\": \"^2.9.0\",\n \"webpack-dev-server\": \"^2.9.1\",\n \"webpack-merge\": \"^4.1.0\"\n },\n \"engines\": {\n \"node\": \"\u003E= 6.0.0\",\n \"npm\": \"\u003E= 3.0.0\"\n },\n \"browserslist\": [\n \"\u003E 1%\",\n \"last 2 versions\",\n \"not ie \u003C= 8\"\n ],\n \"keywords\": [],\n \"jest\": {\n \"moduleFileExtensions\": [\n \"js\",\n \"json\",\n \"vue\"\n ],\n \"transform\": {\n \".*\\\\.(vue)$\": \"vue-jest\",\n \"^.+\\\\.js$\": \"\u003CrootDir\u003E\u002Fnode_modules\u002Fbabel-jest\"\n },\n \"moduleNameMapper\": {\n \"^@\u002F(.*)$\": \"\u003CrootDir\u003E\u002Fsrc\u002F$1\"\n }\n }\n}","id":"bad6f3f6-5816-4e8f-b521-388545e23988","is_binary":false,"title":"package.json","sha":null,"inserted_at":"2018-05-31T12:43:54","updated_at":"2019-03-30T09:59:02","upload_id":null,"shortid":"rk5e89avTk7","source_id":"33dd516a-4865-4483-8f45-a12ee8e866ec","directory_shortid":null},{"code":"import Vue from \"vue\";\nimport Vuex from \"vuex\";\n\nVue.use(Vuex);\n\nexport default new Vuex.Store({\n state: {\n body: \"\",\n source: \"\",\n preview: \"\",\n selection: { start: 0, end: 0 },\n isQuot: 0,\n isWrapP: true,\n isOneLine: false \u002F\u002FSourceを1行で出力\n },\n actions: {\n update({ commit, state }) {\n commit(\"updateBody\", state.body);\n },\n\n getSelection({ commit, state }, e) {\n if (window.getSelection() && typeof e === \"object\" && e.target) {\n commit(\"updateSelection\", {\n start: e.target.selectionStart,\n end: e.target.selectionEnd\n });\n }\n },\n\n surround({ commit, state }, tags) {\n let val = state.body;\n let [before, after] = tags;\n\n let range = val.slice(state.selection.start, state.selection.end);\n let beforeNode = val.slice(0, state.selection.start);\n let afterNode = val.slice(state.selection.end);\n let insertNode = \"\";\n\n if (range || state.selection.start !== state.selection.end) {\n insertNode = before + range + after;\n } else if (state.selection.start === state.selection.end) {\n insertNode = before + after;\n }\n\n commit(\"updateBody\", beforeNode + insertNode + afterNode);\n }\n },\n mutations: {\n updateIsWrapP(state, value) {\n state.isWrapP = value;\n },\n\n updateIsOneLine(state, value) {\n state.isOneLine = value;\n },\n\n updateSource(state, value) {\n state.source = value;\n },\n\n updateIsQuot(state, value) {\n state.isQuot = value;\n },\n\n updateSelection(state, selection) {\n state.selection = selection;\n },\n\n updateBody(state, text) {\n state.body = text;\n\n \u002F\u002FTextarea's character string is split by newline.\n let arr = text.split(\u002F[\\n\\r\\t]{2}\u002Fi);\n let result = [];\n const n = state.isOneLine ? \"\" : \"\\n\";\n\n arr.forEach((w, i) =\u003E {\n \u002F\u002Fw -\u003E One line of a character string divided by line breaks.\n w = w.trim();\n w = w.replace(\u002F^\"\u002F, \"\");\n w = w.replace(\u002F\"$\u002F, \"\");\n\n let isList = \u002F^[・●○〇]\u002F.test(w);\n let isNumList = \u002F^\\s*\\d+\\.\\s*\u002F.test(w);\n\n if (isList) {\n let li = [];\n\n w.split(new RegExp(\u002F^\\s*[・●○〇]\u002F, \"gm\")).forEach(function (ww, ii) {\n if (!ww.length) return;\n ww = ww.replace(\u002F[\\n\\r\\s]+$\u002Fgm, \"\"); \u002F\u002FErase the trailing newline\n ww = ww.replace(\u002F[\\n\\r]\u002Fg, \"\u003Cbr\u003E\");\n ww = ww.replace(\u002F[\\t\\s]*\u002Fgm, \"\");\n li.push(\"\u003Cli\u003E\" + ww + \"\u003C\u002Fli\u003E\");\n });\n\n w = li;\n } else if (isNumList) {\n let li = [];\n w.split(new RegExp(\u002F^\\s*\\d+\\.\\s*\u002F, \"gm\")).forEach(function (ww, ii) {\n if (!ww.length) return;\n ww = ww.replace(\u002F[\\n\\r\\s]+$\u002Fgm, \"\"); \u002F\u002FErase the trailing newline\n ww = ww.replace(\u002F[\\n\\r]\u002Fg, \"\u003Cbr\u003E\");\n ww = ww.replace(\u002F[\\t\\s]*\u002Fgm, \"\");\n li.push(\"\u003Cli\u003E\" + ww + \"\u003C\u002Fli\u003E\");\n });\n w = li;\n } else {\n w = w.replace(\u002F^(■.+)[\\n\\r]*\u002F, \"\u003Cb\u003E$1\u003C\u002Fb\u003E\u003Cbr\u003E\");\n w = w.replace(\u002F([、。]*)[\\n\\r]\u002Fgm, \"$1\u003Cbr\u003E\");\n }\n\n if (!isList && !isNumList) {\n if (state.isWrapP && w.length) {\n w = \"\u003Cp\u003E\" + w + `\u003C\u002Fp\u003E`;\n w = w.replace(\u002F\u003Cbr\u003E\u003C\\\u002Fp\u003E\u002Fgm, `\u003C\u002Fp\u003E`);\n result.push(w);\n } else {\n result.push(w);\n }\n } else {\n result.push(isNumList ? `\u003Col\u003E` : `\u003Cul\u003E`);\n\n result.push(w.join(`${n}`));\n\n result.push(isNumList ? `\u003C\u002Fol\u003E` : `\u003C\u002Ful\u003E`);\n }\n });\n\n state.source = result.join(`${n}`);\n\n state.preview = state.source;\n }\n }\n});\n","id":"b19b4c75-ec27-4d05-b9f1-b199f8b20996","is_binary":false,"title":"index.js","sha":null,"inserted_at":"2018-05-31T12:43:54","updated_at":"2022-06-08T03:28:21","upload_id":null,"shortid":"SJJZIcav61m","source_id":"33dd516a-4865-4483-8f45-a12ee8e866ec","directory_shortid":"B148qTwT1X"}],"base_git":null,"permissions":{"prevent_sandbox_export":false,"prevent_sandbox_leaving":false},"team":{"id":"713ee3f7-f59d-44ff-845c-bc87ba5c7a50","name":"Tenderfeel","settings":{"ai_consent":{"public_sandboxes":false,"private_sandboxes":false}},"subscription_type":null,"avatar_url":"https:\u002F\u002Favatars2.githubusercontent.com\u002Fu\u002F1561936?v=4"},"picks":[],"fork_count":6,"is_frozen":false,"npm_dependencies":{},"git":null,"authorization":"read","always_on":false,"tags":[],"forked_template_sandbox":null,"custom_template":null,"ai_consent":false,"source_id":"33dd516a-4865-4483-8f45-a12ee8e866ec","v2":false,"entry":"src\u002Fmain.js","owned":false,"description":null};