├── .babelrc ├── .editorconfig ├── .gitignore ├── .postcssrc.js ├── Jenkinsfile ├── LICENSE ├── README.md ├── build ├── build.js ├── check-versions.js ├── logo.png ├── utils.js ├── vue-loader.conf.js ├── webpack.base.conf.js ├── webpack.dev.conf.js ├── webpack.prod.conf.js └── webpack.test.conf.js ├── config ├── dev.env.js ├── index.js ├── prod.env.js └── test.env.js ├── index.html ├── package.json ├── src ├── App.vue ├── assets │ ├── images │ │ ├── cards │ │ │ ├── cyborg-chronicles │ │ │ │ └── default.png │ │ │ ├── default.png │ │ │ └── mythos │ │ │ │ ├── chinese │ │ │ │ ├── destruction-tool.jpg │ │ │ │ ├── diyu.jpg │ │ │ │ ├── eight-immortals.jpg │ │ │ │ ├── guan-yu.jpg │ │ │ │ ├── guanyin.jpg │ │ │ │ ├── jade-emperor.jpg │ │ │ │ ├── kung-fu-fighter.jpg │ │ │ │ ├── life-tool.jpg │ │ │ │ ├── manchu-archer.jpg │ │ │ │ ├── mazu.jpg │ │ │ │ ├── monking.jpg │ │ │ │ ├── nuwa.jpg │ │ │ │ ├── shinje.jpg │ │ │ │ ├── terracotta-soldier.jpg │ │ │ │ ├── yaoguai.jpg │ │ │ │ ├── yaojing.jpg │ │ │ │ └── yaomo.jpg │ │ │ │ ├── common │ │ │ │ ├── archer.jpg │ │ │ │ ├── assassin.jpg │ │ │ │ ├── bear.jpg │ │ │ │ ├── defender.jpg │ │ │ │ ├── healer.jpg │ │ │ │ ├── holy-man.jpg │ │ │ │ ├── lost-soul.jpg │ │ │ │ ├── ninja-spy.jpg │ │ │ │ ├── pikeman.jpg │ │ │ │ ├── shaman.jpg │ │ │ │ ├── skeleton.jpg │ │ │ │ ├── slinger.jpg │ │ │ │ ├── snake-python.jpg │ │ │ │ ├── spider.jpg │ │ │ │ ├── swordsman.jpg │ │ │ │ ├── totem.jpg │ │ │ │ └── undead.jpg │ │ │ │ ├── default.png │ │ │ │ ├── greek │ │ │ │ ├── achilles-shield.jpg │ │ │ │ ├── achilles.jpg │ │ │ │ ├── ajax.jpg │ │ │ │ ├── apollo.jpg │ │ │ │ ├── arachne.jpg │ │ │ │ ├── ares.jpg │ │ │ │ ├── artemis.jpg │ │ │ │ ├── athena.jpg │ │ │ │ ├── bident.jpg │ │ │ │ ├── cerberus.jpg │ │ │ │ ├── charon.jpg │ │ │ │ ├── chiron.jpg │ │ │ │ ├── cronus.jpg │ │ │ │ ├── daedalus.jpg │ │ │ │ ├── empusa.jpg │ │ │ │ ├── eros.jpg │ │ │ │ ├── erymanthian-boar.jpg │ │ │ │ ├── gaia.jpg │ │ │ │ ├── golden-fleece.jpg │ │ │ │ ├── griffin.jpg │ │ │ │ ├── hades.jpg │ │ │ │ ├── hecate.jpg │ │ │ │ ├── hector.jpg │ │ │ │ ├── helm-of-darkness.jpg │ │ │ │ ├── hera.jpg │ │ │ │ ├── heracles.jpg │ │ │ │ ├── hermes.jpg │ │ │ │ ├── iolaus.jpg │ │ │ │ ├── judges-of-the-dead.jpg │ │ │ │ ├── lamia.jpg │ │ │ │ ├── lernaean-hydra.jpg │ │ │ │ ├── medusa.jpg │ │ │ │ ├── minotaur.jpg │ │ │ │ ├── mnemosyne.jpg │ │ │ │ ├── moirai.jpg │ │ │ │ ├── mount-olympus.jpg │ │ │ │ ├── nemean-lion.jpg │ │ │ │ ├── odysseus.jpg │ │ │ │ ├── persephone.jpg │ │ │ │ ├── perseus.jpg │ │ │ │ ├── poseidon.jpg │ │ │ │ ├── rhea.jpg │ │ │ │ ├── scythe.jpg │ │ │ │ ├── thanatos.jpg │ │ │ │ ├── theseus.jpg │ │ │ │ ├── trident.jpg │ │ │ │ ├── underworld.jpg │ │ │ │ ├── uranus.jpg │ │ │ │ └── zeus.jpg │ │ │ │ └── hindu │ │ │ │ ├── airavata.jpg │ │ │ │ ├── brahma.jpg │ │ │ │ ├── default.png │ │ │ │ ├── durga.jpg │ │ │ │ ├── gautama-buddha.jpg │ │ │ │ ├── hansa.jpg │ │ │ │ ├── indra.jpg │ │ │ │ ├── krishna.jpg │ │ │ │ ├── maitreya-buddha.jpg │ │ │ │ ├── shiva.jpg │ │ │ │ ├── varuna.jpg │ │ │ │ ├── vishnu.jpg │ │ │ │ └── yama.jpg │ │ └── favicon │ │ │ ├── android-icon-144x144.png │ │ │ ├── android-icon-192x192.png │ │ │ ├── android-icon-36x36.png │ │ │ ├── android-icon-48x48.png │ │ │ ├── android-icon-72x72.png │ │ │ ├── android-icon-96x96.png │ │ │ ├── apple-icon-114x114.png │ │ │ ├── apple-icon-120x120.png │ │ │ ├── apple-icon-144x144.png │ │ │ ├── apple-icon-152x152.png │ │ │ ├── apple-icon-180x180.png │ │ │ ├── apple-icon-57x57.png │ │ │ ├── apple-icon-60x60.png │ │ │ ├── apple-icon-72x72.png │ │ │ ├── apple-icon-76x76.png │ │ │ ├── apple-icon-precomposed.png │ │ │ ├── apple-icon.png │ │ │ ├── browserconfig.xml │ │ │ ├── favicon-16x16.png │ │ │ ├── favicon-32x32.png │ │ │ ├── favicon-96x96.png │ │ │ ├── favicon.ico │ │ │ ├── manifest.json │ │ │ ├── ms-icon-144x144.png │ │ │ ├── ms-icon-150x150.png │ │ │ ├── ms-icon-310x310.png │ │ │ └── ms-icon-70x70.png │ ├── ping_sound.mp3 │ └── style.css ├── components │ ├── CardList.vue │ ├── CardModel.vue │ ├── DeckBuilder.vue │ ├── GameBoard.vue │ ├── Lobby.vue │ ├── Login.vue │ ├── PlayerInfo.vue │ ├── TopNavbar.vue │ └── Value.vue ├── main.js ├── router │ └── index.js └── server_interface.js ├── static └── .gitkeep └── test └── unit ├── .eslintrc ├── index.js ├── karma.conf.js └── specs └── HelloWorld.spec.js /.babelrc: -------------------------------------------------------------------------------- 1 | { 2 | "presets": [ 3 | ["env", { 4 | "modules": false, 5 | "targets": { 6 | "browsers": ["> 1%", "last 2 versions", "not ie <= 8"] 7 | } 8 | }], 9 | "stage-2" 10 | ], 11 | "plugins": ["transform-vue-jsx", "transform-runtime"], 12 | "env": { 13 | "test": { 14 | "presets": ["env", "stage-2"], 15 | "plugins": ["transform-vue-jsx", "istanbul"] 16 | } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /.editorconfig: -------------------------------------------------------------------------------- 1 | root = true 2 | 3 | [*] 4 | charset = utf-8 5 | indent_style = space 6 | indent_size = 2 7 | end_of_line = lf 8 | insert_final_newline = true 9 | trim_trailing_whitespace = true 10 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules/ 3 | /dist/ 4 | npm-debug.log* 5 | yarn-debug.log* 6 | yarn-error.log* 7 | /test/unit/coverage/ 8 | 9 | # Editor directories and files 10 | .idea 11 | .vscode 12 | *.suo 13 | *.ntvs* 14 | *.njsproj 15 | *.sln 16 | /nbproject/ 17 | package-lock.json 18 | 19 | !build/ 20 | !/build/ 21 | !*/build/ 22 | 23 | 24 | -------------------------------------------------------------------------------- /.postcssrc.js: -------------------------------------------------------------------------------- 1 | // https://github.com/michael-ciniawsky/postcss-load-config 2 | 3 | module.exports = { 4 | "plugins": { 5 | "postcss-import": {}, 6 | "postcss-url": {}, 7 | // to edit target browsers: use "browserslist" field in package.json 8 | "autoprefixer": {} 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /Jenkinsfile: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env groovy 2 | 3 | @Library('ZomisJenkins') 4 | import net.zomis.jenkins.Duga 5 | 6 | pipeline { 7 | agent any 8 | 9 | stages { 10 | stage('Prepare') { 11 | steps { 12 | checkout scm 13 | } 14 | } 15 | stage('Build') { 16 | steps { 17 | sh 'npm install && npm run build' 18 | } 19 | } 20 | 21 | stage('Docker Image') { 22 | when { 23 | branch 'master' 24 | } 25 | steps { 26 | script { 27 | sh 'docker ps -q --filter name="cardshifter_client" | xargs -r docker stop' 28 | 29 | sh 'rm -rf /home/zomis/docker-volumes/cardshifter-client' 30 | sh 'cp -r $(pwd)/dist /home/zomis/docker-volumes/cardshifter-client' 31 | sh 'docker run -d --rm --name cardshifter_client -v /home/zomis/docker-volumes/cardshifter-client:/usr/share/nginx/html:ro -p 22739:80 nginx' 32 | } 33 | } 34 | } 35 | 36 | /* 37 | withSonarQubeEnv('My SonarQube Server') { 38 | // requires SonarQube Scanner for Maven 3.2+ 39 | sh 'mvn org.sonarsource.scanner.maven:sonar-maven-plugin:3.2:sonar' 40 | } 41 | */ 42 | } 43 | 44 | post { 45 | success { 46 | zpost(0) 47 | } 48 | unstable { 49 | zpost(1) 50 | } 51 | failure { 52 | zpost(2) 53 | } 54 | } 55 | } 56 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | Apache License 2 | Version 2.0, January 2004 3 | http://www.apache.org/licenses/ 4 | 5 | TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 6 | 7 | 1. Definitions. 8 | 9 | "License" shall mean the terms and conditions for use, reproduction, 10 | and distribution as defined by Sections 1 through 9 of this document. 11 | 12 | "Licensor" shall mean the copyright owner or entity authorized by 13 | the copyright owner that is granting the License. 14 | 15 | "Legal Entity" shall mean the union of the acting entity and all 16 | other entities that control, are controlled by, or are under common 17 | control with that entity. For the purposes of this definition, 18 | "control" means (i) the power, direct or indirect, to cause the 19 | direction or management of such entity, whether by contract or 20 | otherwise, or (ii) ownership of fifty percent (50%) or more of the 21 | outstanding shares, or (iii) beneficial ownership of such entity. 22 | 23 | "You" (or "Your") shall mean an individual or Legal Entity 24 | exercising permissions granted by this License. 25 | 26 | "Source" form shall mean the preferred form for making modifications, 27 | including but not limited to software source code, documentation 28 | source, and configuration files. 29 | 30 | "Object" form shall mean any form resulting from mechanical 31 | transformation or translation of a Source form, including but 32 | not limited to compiled object code, generated documentation, 33 | and conversions to other media types. 34 | 35 | "Work" shall mean the work of authorship, whether in Source or 36 | Object form, made available under the License, as indicated by a 37 | copyright notice that is included in or attached to the work 38 | (an example is provided in the Appendix below). 39 | 40 | "Derivative Works" shall mean any work, whether in Source or Object 41 | form, that is based on (or derived from) the Work and for which the 42 | editorial revisions, annotations, elaborations, or other modifications 43 | represent, as a whole, an original work of authorship. For the purposes 44 | of this License, Derivative Works shall not include works that remain 45 | separable from, or merely link (or bind by name) to the interfaces of, 46 | the Work and Derivative Works thereof. 47 | 48 | "Contribution" shall mean any work of authorship, including 49 | the original version of the Work and any modifications or additions 50 | to that Work or Derivative Works thereof, that is intentionally 51 | submitted to Licensor for inclusion in the Work by the copyright owner 52 | or by an individual or Legal Entity authorized to submit on behalf of 53 | the copyright owner. For the purposes of this definition, "submitted" 54 | means any form of electronic, verbal, or written communication sent 55 | to the Licensor or its representatives, including but not limited to 56 | communication on electronic mailing lists, source code control systems, 57 | and issue tracking systems that are managed by, or on behalf of, the 58 | Licensor for the purpose of discussing and improving the Work, but 59 | excluding communication that is conspicuously marked or otherwise 60 | designated in writing by the copyright owner as "Not a Contribution." 61 | 62 | "Contributor" shall mean Licensor and any individual or Legal Entity 63 | on behalf of whom a Contribution has been received by Licensor and 64 | subsequently incorporated within the Work. 65 | 66 | 2. Grant of Copyright License. Subject to the terms and conditions of 67 | this License, each Contributor hereby grants to You a perpetual, 68 | worldwide, non-exclusive, no-charge, royalty-free, irrevocable 69 | copyright license to reproduce, prepare Derivative Works of, 70 | publicly display, publicly perform, sublicense, and distribute the 71 | Work and such Derivative Works in Source or Object form. 72 | 73 | 3. Grant of Patent License. Subject to the terms and conditions of 74 | this License, each Contributor hereby grants to You a perpetual, 75 | worldwide, non-exclusive, no-charge, royalty-free, irrevocable 76 | (except as stated in this section) patent license to make, have made, 77 | use, offer to sell, sell, import, and otherwise transfer the Work, 78 | where such license applies only to those patent claims licensable 79 | by such Contributor that are necessarily infringed by their 80 | Contribution(s) alone or by combination of their Contribution(s) 81 | with the Work to which such Contribution(s) was submitted. If You 82 | institute patent litigation against any entity (including a 83 | cross-claim or counterclaim in a lawsuit) alleging that the Work 84 | or a Contribution incorporated within the Work constitutes direct 85 | or contributory patent infringement, then any patent licenses 86 | granted to You under this License for that Work shall terminate 87 | as of the date such litigation is filed. 88 | 89 | 4. Redistribution. You may reproduce and distribute copies of the 90 | Work or Derivative Works thereof in any medium, with or without 91 | modifications, and in Source or Object form, provided that You 92 | meet the following conditions: 93 | 94 | (a) You must give any other recipients of the Work or 95 | Derivative Works a copy of this License; and 96 | 97 | (b) You must cause any modified files to carry prominent notices 98 | stating that You changed the files; and 99 | 100 | (c) You must retain, in the Source form of any Derivative Works 101 | that You distribute, all copyright, patent, trademark, and 102 | attribution notices from the Source form of the Work, 103 | excluding those notices that do not pertain to any part of 104 | the Derivative Works; and 105 | 106 | (d) If the Work includes a "NOTICE" text file as part of its 107 | distribution, then any Derivative Works that You distribute must 108 | include a readable copy of the attribution notices contained 109 | within such NOTICE file, excluding those notices that do not 110 | pertain to any part of the Derivative Works, in at least one 111 | of the following places: within a NOTICE text file distributed 112 | as part of the Derivative Works; within the Source form or 113 | documentation, if provided along with the Derivative Works; or, 114 | within a display generated by the Derivative Works, if and 115 | wherever such third-party notices normally appear. The contents 116 | of the NOTICE file are for informational purposes only and 117 | do not modify the License. You may add Your own attribution 118 | notices within Derivative Works that You distribute, alongside 119 | or as an addendum to the NOTICE text from the Work, provided 120 | that such additional attribution notices cannot be construed 121 | as modifying the License. 122 | 123 | You may add Your own copyright statement to Your modifications and 124 | may provide additional or different license terms and conditions 125 | for use, reproduction, or distribution of Your modifications, or 126 | for any such Derivative Works as a whole, provided Your use, 127 | reproduction, and distribution of the Work otherwise complies with 128 | the conditions stated in this License. 129 | 130 | 5. Submission of Contributions. Unless You explicitly state otherwise, 131 | any Contribution intentionally submitted for inclusion in the Work 132 | by You to the Licensor shall be under the terms and conditions of 133 | this License, without any additional terms or conditions. 134 | Notwithstanding the above, nothing herein shall supersede or modify 135 | the terms of any separate license agreement you may have executed 136 | with Licensor regarding such Contributions. 137 | 138 | 6. Trademarks. This License does not grant permission to use the trade 139 | names, trademarks, service marks, or product names of the Licensor, 140 | except as required for reasonable and customary use in describing the 141 | origin of the Work and reproducing the content of the NOTICE file. 142 | 143 | 7. Disclaimer of Warranty. Unless required by applicable law or 144 | agreed to in writing, Licensor provides the Work (and each 145 | Contributor provides its Contributions) on an "AS IS" BASIS, 146 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 147 | implied, including, without limitation, any warranties or conditions 148 | of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A 149 | PARTICULAR PURPOSE. You are solely responsible for determining the 150 | appropriateness of using or redistributing the Work and assume any 151 | risks associated with Your exercise of permissions under this License. 152 | 153 | 8. Limitation of Liability. In no event and under no legal theory, 154 | whether in tort (including negligence), contract, or otherwise, 155 | unless required by applicable law (such as deliberate and grossly 156 | negligent acts) or agreed to in writing, shall any Contributor be 157 | liable to You for damages, including any direct, indirect, special, 158 | incidental, or consequential damages of any character arising as a 159 | result of this License or out of the use or inability to use the 160 | Work (including but not limited to damages for loss of goodwill, 161 | work stoppage, computer failure or malfunction, or any and all 162 | other commercial damages or losses), even if such Contributor 163 | has been advised of the possibility of such damages. 164 | 165 | 9. Accepting Warranty or Additional Liability. While redistributing 166 | the Work or Derivative Works thereof, You may choose to offer, 167 | and charge a fee for, acceptance of support, warranty, indemnity, 168 | or other liability obligations and/or rights consistent with this 169 | License. However, in accepting such obligations, You may act only 170 | on Your own behalf and on Your sole responsibility, not on behalf 171 | of any other Contributor, and only if You agree to indemnify, 172 | defend, and hold each Contributor harmless for any liability 173 | incurred by, or claims asserted against, such Contributor by reason 174 | of your accepting any such warranty or additional liability. 175 | 176 | END OF TERMS AND CONDITIONS 177 | 178 | APPENDIX: How to apply the Apache License to your work. 179 | 180 | To apply the Apache License to your work, attach the following 181 | boilerplate notice, with the fields enclosed by brackets "{}" 182 | replaced with your own identifying information. (Don't include 183 | the brackets!) The text should be enclosed in the appropriate 184 | comment syntax for the file format. We also recommend that a 185 | file or class name and description of purpose be included on the 186 | same "printed page" as the copyright notice for easier 187 | identification within third-party archives. 188 | 189 | Copyright {yyyy} {name of copyright owner} 190 | 191 | Licensed under the Apache License, Version 2.0 (the "License"); 192 | you may not use this file except in compliance with the License. 193 | You may obtain a copy of the License at 194 | 195 | http://www.apache.org/licenses/LICENSE-2.0 196 | 197 | Unless required by applicable law or agreed to in writing, software 198 | distributed under the License is distributed on an "AS IS" BASIS, 199 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 200 | See the License for the specific language governing permissions and 201 | limitations under the License. 202 | 203 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # HTML-Client 2 | 3 | Web-based client for Cardshifter game. To play the game, or for more information about the Cardshifter project, see: 4 | 5 | - [Official website](http://cardshifter.zomis.net/) 6 | 7 | - [Primary repository on GitHub](https://github.com/Cardshifter/Cardshifter) 8 | 9 | ### Development 10 | Ensure you have [NodeJS](https://nodejs.org/) and [npm](https://www.npmjs.com/) installed. Then execute the following instructions using Windows, OS X or Linux terminal: 11 | 12 | ```bash 13 | # browse to a directory on your local machine to clone the repository to 14 | cd C:\path\to\my\projects 15 | # copy this repository 16 | git clone https://www.github.com/cardshifter/html-client 17 | # point your console to that directory 18 | cd HTML-Client 19 | # install dependencies - be patient, this takes a while 20 | npm i 21 | # build the project - takes about 2 minutes 22 | npm run build 23 | # run the client 24 | npm run dev 25 | ``` 26 | 27 | This will host the HTML client at `http://localhost:42637` which you can then access with any web browser. 28 | -------------------------------------------------------------------------------- /build/build.js: -------------------------------------------------------------------------------- 1 | 'use strict' 2 | require('./check-versions')() 3 | 4 | process.env.NODE_ENV = 'production' 5 | 6 | const ora = require('ora') 7 | const rm = require('rimraf') 8 | const path = require('path') 9 | const chalk = require('chalk') 10 | const webpack = require('webpack') 11 | const config = require('../config') 12 | const webpackConfig = require('./webpack.prod.conf') 13 | 14 | const spinner = ora('building for production...') 15 | spinner.start() 16 | 17 | rm(path.join(config.build.assetsRoot, config.build.assetsSubDirectory), err => { 18 | if (err) throw err 19 | webpack(webpackConfig, (err, stats) => { 20 | spinner.stop() 21 | if (err) throw err 22 | process.stdout.write(stats.toString({ 23 | colors: true, 24 | modules: false, 25 | children: false, // If you are using ts-loader, setting this to true will make TypeScript errors show up during build. 26 | chunks: false, 27 | chunkModules: false 28 | }) + '\n\n') 29 | 30 | if (stats.hasErrors()) { 31 | console.log(chalk.red(' Build failed with errors.\n')) 32 | process.exit(1) 33 | } 34 | 35 | console.log(chalk.cyan(' Build complete.\n')) 36 | console.log(chalk.yellow( 37 | ' Tip: built files are meant to be served over an HTTP server.\n' + 38 | ' Opening index.html over file:// won\'t work.\n' 39 | )) 40 | }) 41 | }) 42 | -------------------------------------------------------------------------------- /build/check-versions.js: -------------------------------------------------------------------------------- 1 | 'use strict' 2 | const chalk = require('chalk') 3 | const semver = require('semver') 4 | const packageConfig = require('../package.json') 5 | const shell = require('shelljs') 6 | 7 | function exec (cmd) { 8 | return require('child_process').execSync(cmd).toString().trim() 9 | } 10 | 11 | const versionRequirements = [ 12 | { 13 | name: 'node', 14 | currentVersion: semver.clean(process.version), 15 | versionRequirement: packageConfig.engines.node 16 | } 17 | ] 18 | 19 | if (shell.which('npm')) { 20 | versionRequirements.push({ 21 | name: 'npm', 22 | currentVersion: exec('npm --version'), 23 | versionRequirement: packageConfig.engines.npm 24 | }) 25 | } 26 | 27 | module.exports = function () { 28 | const warnings = [] 29 | 30 | for (let i = 0; i < versionRequirements.length; i++) { 31 | const mod = versionRequirements[i] 32 | 33 | if (!semver.satisfies(mod.currentVersion, mod.versionRequirement)) { 34 | warnings.push(mod.name + ': ' + 35 | chalk.red(mod.currentVersion) + ' should be ' + 36 | chalk.green(mod.versionRequirement) 37 | ) 38 | } 39 | } 40 | 41 | if (warnings.length) { 42 | console.log('') 43 | console.log(chalk.yellow('To use this template, you must update following to modules:')) 44 | console.log() 45 | 46 | for (let i = 0; i < warnings.length; i++) { 47 | const warning = warnings[i] 48 | console.log(' ' + warning) 49 | } 50 | 51 | console.log() 52 | process.exit(1) 53 | } 54 | } 55 | -------------------------------------------------------------------------------- /build/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/build/logo.png -------------------------------------------------------------------------------- /build/utils.js: -------------------------------------------------------------------------------- 1 | 'use strict' 2 | const path = require('path') 3 | const config = require('../config') 4 | const ExtractTextPlugin = require('extract-text-webpack-plugin') 5 | const packageConfig = require('../package.json') 6 | 7 | exports.assetsPath = function (_path) { 8 | const assetsSubDirectory = process.env.NODE_ENV === 'production' 9 | ? config.build.assetsSubDirectory 10 | : config.dev.assetsSubDirectory 11 | 12 | return path.posix.join(assetsSubDirectory, _path) 13 | } 14 | 15 | exports.cssLoaders = function (options) { 16 | options = options || {} 17 | 18 | const cssLoader = { 19 | loader: 'css-loader', 20 | options: { 21 | sourceMap: options.sourceMap 22 | } 23 | } 24 | 25 | const postcssLoader = { 26 | loader: 'postcss-loader', 27 | options: { 28 | sourceMap: options.sourceMap 29 | } 30 | } 31 | 32 | // generate loader string to be used with extract text plugin 33 | function generateLoaders (loader, loaderOptions) { 34 | const loaders = options.usePostCSS ? [cssLoader, postcssLoader] : [cssLoader] 35 | 36 | if (loader) { 37 | loaders.push({ 38 | loader: loader + '-loader', 39 | options: Object.assign({}, loaderOptions, { 40 | sourceMap: options.sourceMap 41 | }) 42 | }) 43 | } 44 | 45 | // Extract CSS when that option is specified 46 | // (which is the case during production build) 47 | if (options.extract) { 48 | return ExtractTextPlugin.extract({ 49 | use: loaders, 50 | fallback: 'vue-style-loader' 51 | }) 52 | } else { 53 | return ['vue-style-loader'].concat(loaders) 54 | } 55 | } 56 | 57 | // https://vue-loader.vuejs.org/en/configurations/extract-css.html 58 | return { 59 | css: generateLoaders(), 60 | postcss: generateLoaders(), 61 | less: generateLoaders('less'), 62 | sass: generateLoaders('sass', { indentedSyntax: true }), 63 | scss: generateLoaders('sass'), 64 | stylus: generateLoaders('stylus'), 65 | styl: generateLoaders('stylus') 66 | } 67 | } 68 | 69 | // Generate loaders for standalone style files (outside of .vue) 70 | exports.styleLoaders = function (options) { 71 | const output = [] 72 | const loaders = exports.cssLoaders(options) 73 | 74 | for (const extension in loaders) { 75 | const loader = loaders[extension] 76 | output.push({ 77 | test: new RegExp('\\.' + extension + '$'), 78 | use: loader 79 | }) 80 | } 81 | 82 | return output 83 | } 84 | 85 | exports.createNotifierCallback = () => { 86 | const notifier = require('node-notifier') 87 | 88 | return (severity, errors) => { 89 | if (severity !== 'error') return 90 | 91 | const error = errors[0] 92 | const filename = error.file && error.file.split('!').pop() 93 | 94 | notifier.notify({ 95 | title: packageConfig.name, 96 | message: severity + ': ' + error.name, 97 | subtitle: filename || '', 98 | icon: path.join(__dirname, 'logo.png') 99 | }) 100 | } 101 | } 102 | -------------------------------------------------------------------------------- /build/vue-loader.conf.js: -------------------------------------------------------------------------------- 1 | 'use strict' 2 | const utils = require('./utils') 3 | const config = require('../config') 4 | const isProduction = process.env.NODE_ENV === 'production' 5 | const sourceMapEnabled = isProduction 6 | ? config.build.productionSourceMap 7 | : config.dev.cssSourceMap 8 | 9 | module.exports = { 10 | loaders: utils.cssLoaders({ 11 | sourceMap: sourceMapEnabled, 12 | extract: isProduction 13 | }), 14 | cssSourceMap: sourceMapEnabled, 15 | cacheBusting: config.dev.cacheBusting, 16 | transformToRequire: { 17 | video: ['src', 'poster'], 18 | source: 'src', 19 | img: 'src', 20 | image: 'xlink:href' 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /build/webpack.base.conf.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | const path = require("path"); 3 | const utils = require("./utils"); 4 | const config = require("../config"); 5 | const vueLoaderConfig = require("./vue-loader.conf"); 6 | 7 | function resolve(dir) { 8 | return path.join(__dirname, "..", dir); 9 | } 10 | 11 | module.exports = { 12 | context: path.resolve(__dirname, "../"), 13 | entry: { 14 | app: "./src/main.js" 15 | }, 16 | output: { 17 | path: config.build.assetsRoot, 18 | filename: "[name].js", 19 | publicPath: 20 | process.env.NODE_ENV === "production" 21 | ? config.build.assetsPublicPath 22 | : config.dev.assetsPublicPath 23 | }, 24 | resolve: { 25 | extensions: [".js", ".vue", ".json"], 26 | alias: { 27 | vue$: "vue/dist/vue.esm.js", 28 | "@": resolve("src") 29 | } 30 | }, 31 | externals: { 32 | }, 33 | module: { 34 | rules: [ 35 | { 36 | test: /\.vue$/, 37 | loader: "vue-loader", 38 | options: vueLoaderConfig 39 | }, 40 | { 41 | test: /\.js$/, 42 | loader: "babel-loader", 43 | include: [ 44 | resolve("src"), 45 | resolve("test"), 46 | resolve("node_modules/webpack-dev-server/client") 47 | ] 48 | }, 49 | { 50 | test: /\.(png|jpe?g|gif|svg)(\?.*)?$/, 51 | loader: "url-loader", 52 | options: { 53 | limit: 10000, 54 | name: utils.assetsPath("img/[name].[hash:7].[ext]") 55 | } 56 | }, 57 | { 58 | test: /\.(mp4|webm|ogg|mp3|wav|flac|aac)(\?.*)?$/, 59 | loader: "url-loader", 60 | options: { 61 | limit: 10000, 62 | name: utils.assetsPath("media/[name].[hash:7].[ext]") 63 | } 64 | }, 65 | { 66 | test: /\.(woff2?|eot|ttf|otf)(\?.*)?$/, 67 | loader: "url-loader", 68 | options: { 69 | limit: 10000, 70 | name: utils.assetsPath("fonts/[name].[hash:7].[ext]") 71 | } 72 | } 73 | ] 74 | }, 75 | node: { 76 | // prevent webpack from injecting useless setImmediate polyfill because Vue 77 | // source contains it (although only uses it if it's native). 78 | setImmediate: false, 79 | // prevent webpack from injecting mocks to Node native modules 80 | // that does not make sense for the client 81 | dgram: "empty", 82 | fs: "empty", 83 | net: "empty", 84 | tls: "empty", 85 | child_process: "empty" 86 | } 87 | }; 88 | -------------------------------------------------------------------------------- /build/webpack.dev.conf.js: -------------------------------------------------------------------------------- 1 | 'use strict' 2 | const utils = require('./utils') 3 | const webpack = require('webpack') 4 | const config = require('../config') 5 | const merge = require('webpack-merge') 6 | const path = require('path') 7 | const baseWebpackConfig = require('./webpack.base.conf') 8 | const CopyWebpackPlugin = require('copy-webpack-plugin') 9 | const HtmlWebpackPlugin = require('html-webpack-plugin') 10 | const FriendlyErrorsPlugin = require('friendly-errors-webpack-plugin') 11 | const portfinder = require('portfinder') 12 | 13 | const HOST = process.env.HOST 14 | const PORT = process.env.PORT && Number(process.env.PORT) 15 | 16 | const devWebpackConfig = merge(baseWebpackConfig, { 17 | module: { 18 | rules: utils.styleLoaders({ sourceMap: config.dev.cssSourceMap, usePostCSS: true }) 19 | }, 20 | // cheap-module-eval-source-map is faster for development 21 | devtool: config.dev.devtool, 22 | 23 | // these devServer options should be customized in /config/index.js 24 | devServer: { 25 | clientLogLevel: 'warning', 26 | historyApiFallback: { 27 | rewrites: [ 28 | { from: /.*/, to: path.posix.join(config.dev.assetsPublicPath, 'index.html') }, 29 | ], 30 | }, 31 | hot: true, 32 | contentBase: false, // since we use CopyWebpackPlugin. 33 | compress: true, 34 | host: HOST || config.dev.host, 35 | port: PORT || config.dev.port, 36 | open: config.dev.autoOpenBrowser, 37 | overlay: config.dev.errorOverlay 38 | ? { warnings: false, errors: true } 39 | : false, 40 | publicPath: config.dev.assetsPublicPath, 41 | proxy: config.dev.proxyTable, 42 | quiet: true, // necessary for FriendlyErrorsPlugin 43 | watchOptions: { 44 | poll: config.dev.poll, 45 | } 46 | }, 47 | plugins: [ 48 | new webpack.DefinePlugin({ 49 | 'process.env': require('../config/dev.env') 50 | }), 51 | new webpack.HotModuleReplacementPlugin(), 52 | new webpack.NamedModulesPlugin(), // HMR shows correct file names in console on update. 53 | new webpack.NoEmitOnErrorsPlugin(), 54 | // https://github.com/ampedandwired/html-webpack-plugin 55 | new HtmlWebpackPlugin({ 56 | filename: 'index.html', 57 | template: 'index.html', 58 | inject: true 59 | }), 60 | // copy custom static assets 61 | new CopyWebpackPlugin([ 62 | { 63 | from: path.resolve(__dirname, '../static'), 64 | to: config.dev.assetsSubDirectory, 65 | ignore: ['.*'] 66 | } 67 | ]) 68 | ] 69 | }) 70 | 71 | module.exports = new Promise((resolve, reject) => { 72 | portfinder.basePort = process.env.PORT || config.dev.port 73 | portfinder.getPort((err, port) => { 74 | if (err) { 75 | reject(err) 76 | } else { 77 | // publish the new Port, necessary for e2e tests 78 | process.env.PORT = port 79 | // add port to devServer config 80 | devWebpackConfig.devServer.port = port 81 | 82 | // Add FriendlyErrorsPlugin 83 | devWebpackConfig.plugins.push(new FriendlyErrorsPlugin({ 84 | compilationSuccessInfo: { 85 | messages: [`Your application is running here: http://${devWebpackConfig.devServer.host}:${port}`], 86 | }, 87 | onErrors: config.dev.notifyOnErrors 88 | ? utils.createNotifierCallback() 89 | : undefined 90 | })) 91 | 92 | resolve(devWebpackConfig) 93 | } 94 | }) 95 | }) 96 | -------------------------------------------------------------------------------- /build/webpack.prod.conf.js: -------------------------------------------------------------------------------- 1 | 'use strict' 2 | const path = require('path') 3 | const utils = require('./utils') 4 | const webpack = require('webpack') 5 | const config = require('../config') 6 | const merge = require('webpack-merge') 7 | const baseWebpackConfig = require('./webpack.base.conf') 8 | const CopyWebpackPlugin = require('copy-webpack-plugin') 9 | const HtmlWebpackPlugin = require('html-webpack-plugin') 10 | const ExtractTextPlugin = require('extract-text-webpack-plugin') 11 | const OptimizeCSSPlugin = require('optimize-css-assets-webpack-plugin') 12 | const UglifyJsPlugin = require('uglifyjs-webpack-plugin') 13 | 14 | const env = process.env.NODE_ENV === 'testing' 15 | ? require('../config/test.env') 16 | : require('../config/prod.env') 17 | 18 | const webpackConfig = merge(baseWebpackConfig, { 19 | module: { 20 | rules: utils.styleLoaders({ 21 | sourceMap: config.build.productionSourceMap, 22 | extract: true, 23 | usePostCSS: true 24 | }) 25 | }, 26 | devtool: config.build.productionSourceMap ? config.build.devtool : false, 27 | output: { 28 | path: config.build.assetsRoot, 29 | filename: utils.assetsPath('js/[name].[chunkhash].js'), 30 | chunkFilename: utils.assetsPath('js/[id].[chunkhash].js') 31 | }, 32 | plugins: [ 33 | // http://vuejs.github.io/vue-loader/en/workflow/production.html 34 | new webpack.DefinePlugin({ 35 | 'process.env': env 36 | }), 37 | new UglifyJsPlugin({ 38 | uglifyOptions: { 39 | compress: { 40 | warnings: false 41 | } 42 | }, 43 | sourceMap: config.build.productionSourceMap, 44 | parallel: true 45 | }), 46 | // extract css into its own file 47 | new ExtractTextPlugin({ 48 | filename: utils.assetsPath('css/[name].[contenthash].css'), 49 | // Setting the following option to `false` will not extract CSS from codesplit chunks. 50 | // Their CSS will instead be inserted dynamically with style-loader when the codesplit chunk has been loaded by webpack. 51 | // It's currently set to `true` because we are seeing that sourcemaps are included in the codesplit bundle as well when it's `false`, 52 | // increasing file size: https://github.com/vuejs-templates/webpack/issues/1110 53 | allChunks: true, 54 | }), 55 | // Compress extracted CSS. We are using this plugin so that possible 56 | // duplicated CSS from different components can be deduped. 57 | new OptimizeCSSPlugin({ 58 | cssProcessorOptions: config.build.productionSourceMap 59 | ? { safe: true, map: { inline: false } } 60 | : { safe: true } 61 | }), 62 | // generate dist index.html with correct asset hash for caching. 63 | // you can customize output by editing /index.html 64 | // see https://github.com/ampedandwired/html-webpack-plugin 65 | new HtmlWebpackPlugin({ 66 | filename: process.env.NODE_ENV === 'testing' 67 | ? 'index.html' 68 | : config.build.index, 69 | template: 'index.html', 70 | inject: true, 71 | minify: { 72 | removeComments: true, 73 | collapseWhitespace: true, 74 | removeAttributeQuotes: true 75 | // more options: 76 | // https://github.com/kangax/html-minifier#options-quick-reference 77 | }, 78 | // necessary to consistently work with multiple chunks via CommonsChunkPlugin 79 | chunksSortMode: 'dependency' 80 | }), 81 | // keep module.id stable when vendor modules does not change 82 | new webpack.HashedModuleIdsPlugin(), 83 | // enable scope hoisting 84 | new webpack.optimize.ModuleConcatenationPlugin(), 85 | // split vendor js into its own file 86 | new webpack.optimize.CommonsChunkPlugin({ 87 | name: 'vendor', 88 | minChunks (module) { 89 | // any required modules inside node_modules are extracted to vendor 90 | return ( 91 | module.resource && 92 | /\.js$/.test(module.resource) && 93 | module.resource.indexOf( 94 | path.join(__dirname, '../node_modules') 95 | ) === 0 96 | ) 97 | } 98 | }), 99 | // extract webpack runtime and module manifest to its own file in order to 100 | // prevent vendor hash from being updated whenever app bundle is updated 101 | new webpack.optimize.CommonsChunkPlugin({ 102 | name: 'manifest', 103 | minChunks: Infinity 104 | }), 105 | // This instance extracts shared chunks from code splitted chunks and bundles them 106 | // in a separate chunk, similar to the vendor chunk 107 | // see: https://webpack.js.org/plugins/commons-chunk-plugin/#extra-async-commons-chunk 108 | new webpack.optimize.CommonsChunkPlugin({ 109 | name: 'app', 110 | async: 'vendor-async', 111 | children: true, 112 | minChunks: 3 113 | }), 114 | 115 | // copy custom static assets 116 | new CopyWebpackPlugin([ 117 | { 118 | from: path.resolve(__dirname, '../static'), 119 | to: config.build.assetsSubDirectory, 120 | ignore: ['.*'] 121 | } 122 | ]) 123 | ] 124 | }) 125 | 126 | if (config.build.productionGzip) { 127 | const CompressionWebpackPlugin = require('compression-webpack-plugin') 128 | 129 | webpackConfig.plugins.push( 130 | new CompressionWebpackPlugin({ 131 | asset: '[path].gz[query]', 132 | algorithm: 'gzip', 133 | test: new RegExp( 134 | '\\.(' + 135 | config.build.productionGzipExtensions.join('|') + 136 | ')$' 137 | ), 138 | threshold: 10240, 139 | minRatio: 0.8 140 | }) 141 | ) 142 | } 143 | 144 | if (config.build.bundleAnalyzerReport) { 145 | const BundleAnalyzerPlugin = require('webpack-bundle-analyzer').BundleAnalyzerPlugin 146 | webpackConfig.plugins.push(new BundleAnalyzerPlugin()) 147 | } 148 | 149 | module.exports = webpackConfig 150 | -------------------------------------------------------------------------------- /build/webpack.test.conf.js: -------------------------------------------------------------------------------- 1 | 'use strict' 2 | // This is the webpack config used for unit tests. 3 | 4 | const utils = require('./utils') 5 | const webpack = require('webpack') 6 | const merge = require('webpack-merge') 7 | const baseWebpackConfig = require('./webpack.base.conf') 8 | 9 | const webpackConfig = merge(baseWebpackConfig, { 10 | // use inline sourcemap for karma-sourcemap-loader 11 | module: { 12 | rules: utils.styleLoaders() 13 | }, 14 | devtool: '#inline-source-map', 15 | resolveLoader: { 16 | alias: { 17 | // necessary to to make lang="scss" work in test when using vue-loader's ?inject option 18 | // see discussion at https://github.com/vuejs/vue-loader/issues/724 19 | 'scss-loader': 'sass-loader' 20 | } 21 | }, 22 | plugins: [ 23 | new webpack.DefinePlugin({ 24 | 'process.env': require('../config/test.env') 25 | }) 26 | ] 27 | }) 28 | 29 | // no need for app entry during tests 30 | delete webpackConfig.entry 31 | 32 | module.exports = webpackConfig 33 | -------------------------------------------------------------------------------- /config/dev.env.js: -------------------------------------------------------------------------------- 1 | 'use strict' 2 | const merge = require('webpack-merge') 3 | const prodEnv = require('./prod.env') 4 | 5 | module.exports = merge(prodEnv, { 6 | NODE_ENV: '"development"' 7 | }) 8 | -------------------------------------------------------------------------------- /config/index.js: -------------------------------------------------------------------------------- 1 | 'use strict' 2 | // Template version: 1.3.1 3 | // see http://vuejs-templates.github.io/webpack for documentation. 4 | 5 | const path = require('path') 6 | 7 | module.exports = { 8 | dev: { 9 | 10 | // Paths 11 | assetsSubDirectory: 'static', 12 | assetsPublicPath: '/', 13 | proxyTable: {}, 14 | 15 | // Various Dev Server settings 16 | host: 'localhost', // can be overwritten by process.env.HOST 17 | port: 42637, // can be overwritten by process.env.PORT, if port is in use, a free one will be determined 18 | autoOpenBrowser: false, 19 | errorOverlay: true, 20 | notifyOnErrors: true, 21 | poll: false, // https://webpack.js.org/configuration/dev-server/#devserver-watchoptions- 22 | 23 | 24 | /** 25 | * Source Maps 26 | */ 27 | 28 | // https://webpack.js.org/configuration/devtool/#development 29 | devtool: 'cheap-module-eval-source-map', 30 | 31 | // If you have problems debugging vue-files in devtools, 32 | // set this to false - it *may* help 33 | // https://vue-loader.vuejs.org/en/options.html#cachebusting 34 | cacheBusting: true, 35 | 36 | cssSourceMap: true 37 | }, 38 | 39 | build: { 40 | // Template for index.html 41 | index: path.resolve(__dirname, '../dist/index.html'), 42 | 43 | // Paths 44 | assetsRoot: path.resolve(__dirname, '../dist'), 45 | assetsSubDirectory: 'static', 46 | assetsPublicPath: '/', 47 | 48 | /** 49 | * Source Maps 50 | */ 51 | 52 | productionSourceMap: true, 53 | // https://webpack.js.org/configuration/devtool/#production 54 | devtool: '#source-map', 55 | 56 | // Gzip off by default as many popular static hosts such as 57 | // Surge or Netlify already gzip all static assets for you. 58 | // Before setting to `true`, make sure to: 59 | // npm install --save-dev compression-webpack-plugin 60 | productionGzip: false, 61 | productionGzipExtensions: ['js', 'css'], 62 | 63 | // Run the build command with an extra argument to 64 | // View the bundle analyzer report after build finishes: 65 | // `npm run build --report` 66 | // Set to `true` or `false` to always turn it on or off 67 | bundleAnalyzerReport: process.env.npm_config_report 68 | } 69 | } 70 | -------------------------------------------------------------------------------- /config/prod.env.js: -------------------------------------------------------------------------------- 1 | 'use strict' 2 | module.exports = { 3 | NODE_ENV: '"production"' 4 | } 5 | -------------------------------------------------------------------------------- /config/test.env.js: -------------------------------------------------------------------------------- 1 | 'use strict' 2 | const merge = require('webpack-merge') 3 | const devEnv = require('./dev.env') 4 | 5 | module.exports = merge(devEnv, { 6 | NODE_ENV: '"testing"' 7 | }) 8 | -------------------------------------------------------------------------------- /index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Cardshifter 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 |
30 |
31 |
32 | 33 | 34 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "cardshifter-client", 3 | "version": "1.0.0", 4 | "description": "Vue-Client for Cardshifter", 5 | "private": true, 6 | "scripts": { 7 | "dev": "webpack-dev-server --inline --progress --host 0.0.0.0 --config build/webpack.dev.conf.js", 8 | "start": "npm run dev", 9 | "unit": "cross-env BABEL_ENV=test karma start test/unit/karma.conf.js --single-run", 10 | "test": "npm run unit", 11 | "build": "node build/build.js" 12 | }, 13 | "dependencies": { 14 | "axios": "^0.18.0", 15 | "bootstrap-vue": "^2.0.0-rc.10", 16 | "vue": "^2.5.2", 17 | "vue-authenticate": "^1.3.4", 18 | "vue-router": "^3.0.1" 19 | }, 20 | "devDependencies": { 21 | "autoprefixer": "^7.1.2", 22 | "babel-core": "^6.22.1", 23 | "babel-helper-vue-jsx-merge-props": "^2.0.3", 24 | "babel-loader": "^7.1.1", 25 | "babel-plugin-istanbul": "^4.1.1", 26 | "babel-plugin-syntax-jsx": "^6.18.0", 27 | "babel-plugin-transform-runtime": "^6.22.0", 28 | "babel-plugin-transform-vue-jsx": "^3.5.0", 29 | "babel-preset-env": "^1.3.2", 30 | "babel-preset-stage-2": "^6.22.0", 31 | "chai": "^4.1.2", 32 | "chalk": "^2.0.1", 33 | "copy-webpack-plugin": "^4.0.1", 34 | "cross-env": "^5.0.1", 35 | "css-loader": "^0.28.0", 36 | "extract-text-webpack-plugin": "^3.0.0", 37 | "file-loader": "^1.1.4", 38 | "friendly-errors-webpack-plugin": "^1.6.1", 39 | "html-webpack-plugin": "^2.30.1", 40 | "inject-loader": "^3.0.0", 41 | "karma": "^1.4.1", 42 | "karma-coverage": "^1.1.1", 43 | "karma-mocha": "^1.3.0", 44 | "karma-phantomjs-launcher": "^1.0.2", 45 | "karma-phantomjs-shim": "^1.4.0", 46 | "karma-sinon-chai": "^1.3.1", 47 | "karma-sourcemap-loader": "^0.3.7", 48 | "karma-spec-reporter": "0.0.31", 49 | "karma-webpack": "^2.0.2", 50 | "mocha": "^3.2.0", 51 | "node-notifier": "^5.1.2", 52 | "optimize-css-assets-webpack-plugin": "^3.2.0", 53 | "ora": "^1.2.0", 54 | "phantomjs-prebuilt": "^2.1.14", 55 | "portfinder": "^1.0.13", 56 | "postcss-import": "^11.0.0", 57 | "postcss-loader": "^2.0.8", 58 | "postcss-url": "^7.2.1", 59 | "rimraf": "^2.6.0", 60 | "semver": "^5.3.0", 61 | "shelljs": "^0.7.6", 62 | "sinon": "^4.0.0", 63 | "sinon-chai": "^2.8.0", 64 | "uglifyjs-webpack-plugin": "^1.1.1", 65 | "url-loader": "^0.5.8", 66 | "vue-loader": "^13.3.0", 67 | "vue-style-loader": "^3.0.1", 68 | "vue-template-compiler": "^2.5.2", 69 | "webpack": "^3.6.0", 70 | "webpack-bundle-analyzer": "^2.9.0", 71 | "webpack-dev-server": "^2.9.1", 72 | "webpack-merge": "^4.1.0" 73 | }, 74 | "prettier": { 75 | "tabWidth": 4 76 | }, 77 | "engines": { 78 | "node": ">= 6.0.0", 79 | "npm": ">= 3.0.0" 80 | }, 81 | "browserslist": [ 82 | "> 1%", 83 | "last 2 versions", 84 | "not ie <= 8" 85 | ] 86 | } 87 | -------------------------------------------------------------------------------- /src/App.vue: -------------------------------------------------------------------------------- 1 | 15 | 16 | 26 | 27 | 39 | -------------------------------------------------------------------------------- /src/assets/images/cards/cyborg-chronicles/default.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/cyborg-chronicles/default.png -------------------------------------------------------------------------------- /src/assets/images/cards/default.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/default.png -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/chinese/destruction-tool.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/chinese/destruction-tool.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/chinese/diyu.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/chinese/diyu.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/chinese/eight-immortals.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/chinese/eight-immortals.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/chinese/guan-yu.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/chinese/guan-yu.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/chinese/guanyin.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/chinese/guanyin.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/chinese/jade-emperor.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/chinese/jade-emperor.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/chinese/kung-fu-fighter.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/chinese/kung-fu-fighter.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/chinese/life-tool.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/chinese/life-tool.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/chinese/manchu-archer.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/chinese/manchu-archer.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/chinese/mazu.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/chinese/mazu.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/chinese/monking.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/chinese/monking.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/chinese/nuwa.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/chinese/nuwa.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/chinese/shinje.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/chinese/shinje.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/chinese/terracotta-soldier.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/chinese/terracotta-soldier.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/chinese/yaoguai.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/chinese/yaoguai.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/chinese/yaojing.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/chinese/yaojing.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/chinese/yaomo.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/chinese/yaomo.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/common/archer.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/common/archer.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/common/assassin.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/common/assassin.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/common/bear.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/common/bear.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/common/defender.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/common/defender.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/common/healer.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/common/healer.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/common/holy-man.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/common/holy-man.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/common/lost-soul.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/common/lost-soul.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/common/ninja-spy.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/common/ninja-spy.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/common/pikeman.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/common/pikeman.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/common/shaman.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/common/shaman.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/common/skeleton.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/common/skeleton.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/common/slinger.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/common/slinger.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/common/snake-python.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/common/snake-python.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/common/spider.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/common/spider.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/common/swordsman.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/common/swordsman.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/common/totem.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/common/totem.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/common/undead.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/common/undead.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/default.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/default.png -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/achilles-shield.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/achilles-shield.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/achilles.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/achilles.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/ajax.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/ajax.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/apollo.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/apollo.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/arachne.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/arachne.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/ares.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/ares.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/artemis.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/artemis.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/athena.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/athena.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/bident.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/bident.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/cerberus.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/cerberus.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/charon.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/charon.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/chiron.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/chiron.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/cronus.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/cronus.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/daedalus.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/daedalus.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/empusa.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/empusa.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/eros.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/eros.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/erymanthian-boar.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/erymanthian-boar.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/gaia.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/gaia.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/golden-fleece.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/golden-fleece.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/griffin.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/griffin.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/hades.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/hades.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/hecate.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/hecate.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/hector.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/hector.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/helm-of-darkness.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/helm-of-darkness.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/hera.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/hera.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/heracles.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/heracles.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/hermes.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/hermes.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/iolaus.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/iolaus.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/judges-of-the-dead.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/judges-of-the-dead.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/lamia.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/lamia.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/lernaean-hydra.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/lernaean-hydra.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/medusa.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/medusa.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/minotaur.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/minotaur.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/mnemosyne.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/mnemosyne.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/moirai.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/moirai.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/mount-olympus.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/mount-olympus.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/nemean-lion.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/nemean-lion.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/odysseus.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/odysseus.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/persephone.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/persephone.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/perseus.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/perseus.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/poseidon.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/poseidon.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/rhea.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/rhea.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/scythe.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/scythe.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/thanatos.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/thanatos.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/theseus.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/theseus.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/trident.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/trident.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/underworld.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/underworld.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/uranus.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/uranus.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/greek/zeus.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/greek/zeus.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/hindu/airavata.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/hindu/airavata.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/hindu/brahma.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/hindu/brahma.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/hindu/default.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/hindu/default.png -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/hindu/durga.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/hindu/durga.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/hindu/gautama-buddha.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/hindu/gautama-buddha.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/hindu/hansa.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/hindu/hansa.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/hindu/indra.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/hindu/indra.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/hindu/krishna.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/hindu/krishna.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/hindu/maitreya-buddha.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/hindu/maitreya-buddha.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/hindu/shiva.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/hindu/shiva.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/hindu/varuna.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/hindu/varuna.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/hindu/vishnu.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/hindu/vishnu.jpg -------------------------------------------------------------------------------- /src/assets/images/cards/mythos/hindu/yama.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/cards/mythos/hindu/yama.jpg -------------------------------------------------------------------------------- /src/assets/images/favicon/android-icon-144x144.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/favicon/android-icon-144x144.png -------------------------------------------------------------------------------- /src/assets/images/favicon/android-icon-192x192.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/favicon/android-icon-192x192.png -------------------------------------------------------------------------------- /src/assets/images/favicon/android-icon-36x36.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/favicon/android-icon-36x36.png -------------------------------------------------------------------------------- /src/assets/images/favicon/android-icon-48x48.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/favicon/android-icon-48x48.png -------------------------------------------------------------------------------- /src/assets/images/favicon/android-icon-72x72.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/favicon/android-icon-72x72.png -------------------------------------------------------------------------------- /src/assets/images/favicon/android-icon-96x96.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/favicon/android-icon-96x96.png -------------------------------------------------------------------------------- /src/assets/images/favicon/apple-icon-114x114.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/favicon/apple-icon-114x114.png -------------------------------------------------------------------------------- /src/assets/images/favicon/apple-icon-120x120.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/favicon/apple-icon-120x120.png -------------------------------------------------------------------------------- /src/assets/images/favicon/apple-icon-144x144.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/favicon/apple-icon-144x144.png -------------------------------------------------------------------------------- /src/assets/images/favicon/apple-icon-152x152.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/favicon/apple-icon-152x152.png -------------------------------------------------------------------------------- /src/assets/images/favicon/apple-icon-180x180.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/favicon/apple-icon-180x180.png -------------------------------------------------------------------------------- /src/assets/images/favicon/apple-icon-57x57.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/favicon/apple-icon-57x57.png -------------------------------------------------------------------------------- /src/assets/images/favicon/apple-icon-60x60.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/favicon/apple-icon-60x60.png -------------------------------------------------------------------------------- /src/assets/images/favicon/apple-icon-72x72.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/favicon/apple-icon-72x72.png -------------------------------------------------------------------------------- /src/assets/images/favicon/apple-icon-76x76.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/favicon/apple-icon-76x76.png -------------------------------------------------------------------------------- /src/assets/images/favicon/apple-icon-precomposed.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/favicon/apple-icon-precomposed.png -------------------------------------------------------------------------------- /src/assets/images/favicon/apple-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/favicon/apple-icon.png -------------------------------------------------------------------------------- /src/assets/images/favicon/browserconfig.xml: -------------------------------------------------------------------------------- 1 | 2 | #ffffff -------------------------------------------------------------------------------- /src/assets/images/favicon/favicon-16x16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/favicon/favicon-16x16.png -------------------------------------------------------------------------------- /src/assets/images/favicon/favicon-32x32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/favicon/favicon-32x32.png -------------------------------------------------------------------------------- /src/assets/images/favicon/favicon-96x96.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/favicon/favicon-96x96.png -------------------------------------------------------------------------------- /src/assets/images/favicon/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/favicon/favicon.ico -------------------------------------------------------------------------------- /src/assets/images/favicon/manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "App", 3 | "icons": [ 4 | { 5 | "src": "\/android-icon-36x36.png", 6 | "sizes": "36x36", 7 | "type": "image\/png", 8 | "density": "0.75" 9 | }, 10 | { 11 | "src": "\/android-icon-48x48.png", 12 | "sizes": "48x48", 13 | "type": "image\/png", 14 | "density": "1.0" 15 | }, 16 | { 17 | "src": "\/android-icon-72x72.png", 18 | "sizes": "72x72", 19 | "type": "image\/png", 20 | "density": "1.5" 21 | }, 22 | { 23 | "src": "\/android-icon-96x96.png", 24 | "sizes": "96x96", 25 | "type": "image\/png", 26 | "density": "2.0" 27 | }, 28 | { 29 | "src": "\/android-icon-144x144.png", 30 | "sizes": "144x144", 31 | "type": "image\/png", 32 | "density": "3.0" 33 | }, 34 | { 35 | "src": "\/android-icon-192x192.png", 36 | "sizes": "192x192", 37 | "type": "image\/png", 38 | "density": "4.0" 39 | } 40 | ] 41 | } -------------------------------------------------------------------------------- /src/assets/images/favicon/ms-icon-144x144.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/favicon/ms-icon-144x144.png -------------------------------------------------------------------------------- /src/assets/images/favicon/ms-icon-150x150.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/favicon/ms-icon-150x150.png -------------------------------------------------------------------------------- /src/assets/images/favicon/ms-icon-310x310.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/favicon/ms-icon-310x310.png -------------------------------------------------------------------------------- /src/assets/images/favicon/ms-icon-70x70.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/images/favicon/ms-icon-70x70.png -------------------------------------------------------------------------------- /src/assets/ping_sound.mp3: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/src/assets/ping_sound.mp3 -------------------------------------------------------------------------------- /src/assets/style.css: -------------------------------------------------------------------------------- 1 | body { 2 | font-size: 120%; 3 | font-family: Verdana, Geneva, sans-serif; 4 | } 5 | 6 | /* FORMATTING SPECIFIC TO LOGIN FORM */ 7 | 8 | .login-form { 9 | font-size: 1.2em; 10 | font-weight: normal; 11 | width: 50%; 12 | } 13 | 14 | label { 15 | font-size: 1.0em; 16 | } 17 | 18 | button, input, select, textarea { 19 | font-size: 1.0em; 20 | font-family: Verdana, Geneva, sans-serif; 21 | padding-bottom: 0px; 22 | } 23 | 24 | /* FORMATTING FOR TOP NAV BAR */ 25 | 26 | .csh-top-link { 27 | font-family: Georgia, Times, "Times New Roman", serif; 28 | color: #AAAAAA; 29 | font-size: 2em; 30 | } 31 | 32 | .csh-top-link:hover, .csh-top-link:active { 33 | color: #EEEEEE; 34 | } 35 | 36 | a.csh-dropdown-link, 37 | a.csh-dropdown-link:visited { 38 | color: #DDDDDD; 39 | font-size: 1.4em; 40 | font-family: Georgia, Times, "Times New Roman", serif; 41 | } 42 | 43 | a.csh-dropdown-link:hover, 44 | a.csh-dropdown-link:active { 45 | color: #DDDDDD; 46 | /*text-decoration: underline;*/ 47 | font-family: Georgia, Times, "Times New Roman", serif; 48 | } 49 | 50 | .btn.btn-navbar { 51 | color: #DDDDDD; 52 | background-color: #000000; 53 | /* background-image: linear-gradient(to bottom, #8f8f8f, #4a4a49); */ 54 | border-color: #DDDDDD #DDDDDD #DDDDDD; 55 | } 56 | .btn.btn-navbar:hover { 57 | color: #FFFFFF; 58 | background-color: #DDDDDD; 59 | background-image: linear-gradient(to bottom, #4a4a49, #4a4a49); 60 | border-color: #FFFFFF #FFFFFF #FFFFFF; 61 | } 62 | 63 | .csh-twitter-top-bar { 64 | list-style: none; 65 | margin: 0; 66 | } 67 | 68 | .csh-twitter-top-bar > li { 69 | display: inline-block !important; 70 | } 71 | 72 | .twitter-logo { 73 | height: 25px; 74 | width: 30px; 75 | margin-top: 10px; 76 | -left: 5px; 77 | } 78 | 79 | 80 | /* FORMATTING FOR SERVER CONSOLE */ 81 | 82 | div#server-console { 83 | font-family: Monaco, Consolas, "Courier New", monospace; 84 | font-size: 1.0em; 85 | font-weight: normal; 86 | color: #AAAAAA; 87 | background-color: #222222; 88 | height: 250px; 89 | overflow: scroll; 90 | } 91 | 92 | /* FORMATTING FOR PAGE BODY */ 93 | 94 | .csh-body { 95 | padding-left: 15px; 96 | } 97 | 98 | /* FORMATTING FOR FOOTER */ 99 | 100 | html { 101 | position: relative; 102 | min-height: 100%; 103 | } 104 | body { 105 | margin-bottom: 60px; 106 | } 107 | 108 | .footer { 109 | position: absolute; 110 | bottom: 0; 111 | margin-top: 15px; 112 | padding: 5px 0 5px 15px; 113 | border-top: 1px solid #eaeaea; 114 | color: #777; 115 | width: 100%; 116 | text-align: center; 117 | /* Set the fixed height of the footer here */ 118 | height: 30px; 119 | background-color: #f5f5f5; 120 | position: absolute; 121 | bottom: 0px; 122 | } 123 | 124 | /* FORMATTING FOR COMMON PAGE ELEMENTS */ 125 | 126 | .header-border { 127 | border-bottom: 1px solid #eee; 128 | } 129 | 130 | h1, h2, h3, h4, blockquote { 131 | font-family: Georgia, Times, "Times New Roman", serif; 132 | } 133 | 134 | p, span, table, ul, ol { 135 | font-size: 1.2em; 136 | font-weight: normal; 137 | } 138 | 139 | pre { 140 | font-family: Monaco, Consolas, "Courier New", monospace; 141 | font-size: 1.1em; 142 | font-weight: normal; 143 | } 144 | 145 | code { 146 | font-family: Monaco, Consolas, "Courier New", monospace; 147 | font-size: 1.1em; 148 | color: #336699; 149 | background-color: #EEEEEE; 150 | } 151 | 152 | blockquote { 153 | font-size: 1.4em; 154 | } 155 | 156 | div.contributor { 157 | margin-bottom: 10px; 158 | margin-top: 10px; 159 | width: 350px; 160 | } 161 | 162 | /* MOD-SPECIFIC FORMATTING */ 163 | 164 | .cyborg-font { 165 | font-family: Monaco, Consolas, "Courier New", monospace; 166 | } 167 | 168 | .mythos-font { 169 | font-family: Copperplate, Copperplate Gothic Light, fantasy; 170 | } 171 | 172 | /* FORMATTING FOR ARTICLES */ 173 | 174 | article {} 175 | 176 | h2.csh-article { 177 | font-size: 2.4em; 178 | text-decoration: underline; 179 | } 180 | 181 | h3.csh-article { 182 | font-size: 2.0em; 183 | } 184 | 185 | a.csh-article { 186 | text-decoration: underline; 187 | } 188 | 189 | section.csh-article { 190 | padding-left: 5px; 191 | } 192 | 193 | p.csh-article-header { 194 | font-size: 1.2em; 195 | font-style: italic; 196 | font-family: Georgia, Times, "Times New Roman", serif; 197 | } 198 | 199 | p.csh-article-content { 200 | padding-left: 10px; 201 | font-size: 1.2em; 202 | } 203 | 204 | p.csh-article-footer { 205 | font-size: 1.2em; 206 | padding-left: 5px; 207 | font-style: italic; 208 | font-family: Georgia, Times, "Times New Roman", serif; 209 | } 210 | 211 | ul.csh-article-list, 212 | ol.csh-article-list { 213 | font-size: 1.2em; 214 | } 215 | 216 | 217 | /* FORMATTING FOR TABLES */ 218 | 219 | table, th, td { 220 | border: 1px solid black; 221 | border-collapse: collapse; 222 | } 223 | 224 | th, td { 225 | padding: 5px; 226 | } 227 | 228 | th { 229 | background-color: #EEEEEE; 230 | color: #000000; 231 | } 232 | 233 | /* FORMATTING FOR BUTTONS, ALERTS, ETC. */ 234 | 235 | .csh-button { 236 | font-size: 1.1em; 237 | font-weight: normal; 238 | } 239 | 240 | /* FORMATTING FOR GAME-BOARD STUFF */ 241 | 242 | 243 | .targetable { 244 | background-color: yellow; 245 | } 246 | 247 | .selected { 248 | background-color: #00ffff; 249 | } 250 | 251 | .player-info-box { 252 | /*border: solid 3px yellow;*/ /* for testing */ 253 | /* Layout & Positioning */ 254 | height: 300px; 255 | width: 14%; 256 | float: left; 257 | /* Styling: */ 258 | border: double 3px #7A7A7A; 259 | background-color: #F5F5F5; 260 | border-radius: 10px; 261 | /* Content alignment */ 262 | text-align: left; 263 | padding-left: 5px; 264 | font-size: 0.8em; 265 | } 266 | 267 | .player-actions { 268 | } 269 | 270 | .card-property { 271 | position: relative; 272 | } 273 | 274 | .player-user .zone-Hand { 275 | /*border: solid 3px red;*/ 276 | height: 300px; 277 | width: 86%; 278 | overflow-y: scroll; 279 | float: left; 280 | /* Styling: */ 281 | border: double 3px #BBBBBB; 282 | background-color: #EEEEEE; 283 | border-radius: 10px; 284 | } 285 | 286 | .player-user .zone-Battlefield { 287 | /*border: solid 3px pink;*/ 288 | height: 300px; 289 | width: 86%; 290 | overflow-y: scroll; 291 | float: left; 292 | /* Styling: */ 293 | border: double 3px #1F3D7A; 294 | background-color: #C2D1F0; 295 | border-radius: 10px; 296 | } 297 | 298 | .player-opponent .zone-Hand { 299 | visibility: hidden; /* THERE IS NOTHING TO SHOW IN THIS SECTION RIGHT NOW - @Phrancis 2015-08-27 */ 300 | /*border: solid 3px blue;*/ 301 | height: 300px; 302 | width: 3%; 303 | } 304 | 305 | .player-opponent .zone-Battlefield { 306 | /*border: solid 3px teal;*/ 307 | height: 300px; 308 | width: 100%; 309 | overflow-y: scroll; 310 | /* Styling: */ 311 | border: double 3px #7A0000; 312 | background-color: #E68080; 313 | border-radius: 10px; 314 | } 315 | 316 | 317 | .list-complete-item { 318 | transition: all 1s; 319 | display: inline-block; 320 | margin-right: 10px; 321 | } 322 | 323 | .list-complete-enter, .list-complete-leave-to { 324 | opacity: 0; 325 | transform: translateY(30px); 326 | } 327 | 328 | .list-complete-leave-active { 329 | position: absolute; 330 | } 331 | -------------------------------------------------------------------------------- /src/components/CardList.vue: -------------------------------------------------------------------------------- 1 | 26 | 83 | 88 | -------------------------------------------------------------------------------- /src/components/CardModel.vue: -------------------------------------------------------------------------------- 1 | 78 | 148 | 255 | -------------------------------------------------------------------------------- /src/components/DeckBuilder.vue: -------------------------------------------------------------------------------- 1 | 94 | 485 | 507 | -------------------------------------------------------------------------------- /src/components/GameBoard.vue: -------------------------------------------------------------------------------- 1 | 45 | 521 | -------------------------------------------------------------------------------- /src/components/Lobby.vue: -------------------------------------------------------------------------------- 1 | 84 | 85 | 329 | 330 | 480 | -------------------------------------------------------------------------------- /src/components/Login.vue: -------------------------------------------------------------------------------- 1 | 108 | 109 | 270 | 271 | 298 | -------------------------------------------------------------------------------- /src/components/PlayerInfo.vue: -------------------------------------------------------------------------------- 1 | 52 | 87 | -------------------------------------------------------------------------------- /src/components/TopNavbar.vue: -------------------------------------------------------------------------------- 1 | 13 | 14 | 24 | 25 | 38 | -------------------------------------------------------------------------------- /src/components/Value.vue: -------------------------------------------------------------------------------- 1 | 14 | 96 | 117 | -------------------------------------------------------------------------------- /src/main.js: -------------------------------------------------------------------------------- 1 | // The Vue build version to load with the `import` command 2 | // (runtime-only or standalone) has been set in webpack.base.conf with an alias. 3 | import Vue from "vue"; 4 | import App from "./App"; 5 | import router from "./router"; 6 | import BootstrapVue from "bootstrap-vue"; 7 | import "bootstrap/dist/css/bootstrap.css"; 8 | import "bootstrap-vue/dist/bootstrap-vue.css"; 9 | 10 | Vue.use(BootstrapVue); 11 | 12 | Vue.config.productionTip = false; 13 | 14 | /* eslint-disable no-new */ 15 | new Vue({ 16 | el: "#app", 17 | router, 18 | components: { App }, 19 | template: "" 20 | }); 21 | -------------------------------------------------------------------------------- /src/router/index.js: -------------------------------------------------------------------------------- 1 | import Vue from "vue"; 2 | import Router from "vue-router"; 3 | import TopNavbar from "@/components/TopNavbar"; 4 | import Login from "@/components/Login"; 5 | import Lobby from "@/components/Lobby"; 6 | import DeckBuilder from "@/components/DeckBuilder"; 7 | import CardList from "@/components/CardList"; 8 | import GameBoard from "@/components/GameBoard"; 9 | 10 | import VueAxios from "vue-axios"; 11 | import VueAuthenticate from "vue-authenticate"; 12 | import axios from "axios"; 13 | 14 | // Vue.use(VueAxios, axios); 15 | // Vue.use(VueAuthenticate, { 16 | // baseUrl: "http://cardshifter.zomis.net:22738", // Your API domain 17 | // providers: { 18 | // github: { 19 | // clientId: "", 20 | // redirectUri: "http://cardshifter.zomis.net/" 21 | // } 22 | // } 23 | // }); 24 | 25 | Vue.use(Router); 26 | 27 | export default new Router({ 28 | routes: [ 29 | { 30 | path: "/game_board", 31 | name: "GameBoard", 32 | component: GameBoard, 33 | props: true 34 | }, 35 | { 36 | path: "/cards", 37 | name: "CardList", 38 | component: CardList, 39 | props: (route) => ({ 40 | server: route.query.server, 41 | mod: route.query.mod 42 | }) 43 | }, 44 | { 45 | path: "/deck_builder/", 46 | name: "DeckBuilder", 47 | component: DeckBuilder, 48 | props: true 49 | }, 50 | { 51 | path: "/lobby", 52 | name: "Lobby", 53 | component: Lobby, 54 | props: true 55 | }, 56 | { 57 | path: "/", 58 | name: "Login", 59 | component: Login 60 | } 61 | ] 62 | }); 63 | -------------------------------------------------------------------------------- /src/server_interface.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | import Vue from "vue"; 4 | 5 | // checks if the string begins with either ws:// or wss:// 6 | var wsProtocolFinder = /ws(s)?:\/\//; 7 | var SOCKET_OPEN = 1; 8 | 9 | var MAIN_LOBBY = 1; 10 | 11 | /** 12 | * The base class Message for all the other message types 13 | * to inherit from. 14 | * 15 | * TODO: Would it just be easier to set the .command property 16 | * individually for each card type? 17 | */ 18 | function Message(command) { 19 | this.command = command; 20 | } 21 | 22 | /** 23 | * The exception that is thrown when the code is trying to 24 | * interact with the API when the API has not been 25 | * initialized with .init yet. 26 | */ 27 | function NotInitializedException(message) { 28 | this.name = "NotInitializedException"; 29 | this.message = message; 30 | } 31 | 32 | /** 33 | * The exception that is thrown when the code is telling the 34 | * API to interact with the socket when the socket is not 35 | * ready to accept any information. 36 | */ 37 | function SocketNotReadyException(message, readyState) { 38 | this.name = "SocketNotReadyException" 39 | this.message = message; 40 | this.readyState = readyState; 41 | } 42 | 43 | /** 44 | Returns all the keys of obj and it's inherited keys 45 | 46 | @param obj:Object -- The object 47 | @return Object -- a new Object, containing obj's keys and inherited keys 48 | @source http://stackoverflow.com/questions/8779249/how-to-stringify-inherited-objects-to-json 49 | 50 | This is used so JSON.stringify can get the .command of a message. 51 | */ 52 | function flatten(obj) { 53 | var result = Object.create(obj); 54 | for(var key in result) { 55 | result[key] = result[key]; 56 | } 57 | return result; 58 | } 59 | 60 | const CardshifterServerAPI = new Vue({ 61 | data() { 62 | return { 63 | socket: null, 64 | messageTypes: { 65 | /** 66 | * Incoming login message. 67 | *

68 | * A login message from a client to add a user to the available users on the server. 69 | * This login message is required before any other action or message can be performed between a client and a server. 70 | * @constructor 71 | * @param username the incoming user name passed from client to server, not null 72 | * @example Message: { "command":"login","username":"JohnDoe" } 73 | */ 74 | LoginMessage: function(username) { 75 | this.username = username; 76 | console.log(this); 77 | }, 78 | 79 | /** 80 | * Request available targets for a specific action to be performed by an entity. 81 | *

82 | * These in-game messages request a list of al available targets for a given action and entity. 83 | * The client uses this request in order to point out targets (hopefully with a visual aid such as highlighting targets) 84 | * that an entity (such as a creature card, or a player) can perform an action on (for example attack or enchant a card. 85 | * @constructor 86 | * @param gameId The Id of this game currently being played 87 | * @param id The Id of this entity which requests to perform an action 88 | * @param action The name of this action requested to be performed 89 | */ 90 | RequestTargetsMessage: function(gameId, id, action) { 91 | this.gameId = gameId; 92 | this.id = id; 93 | this.action = action; 94 | }, 95 | 96 | /** 97 | * Make a specific type of request to the server. 98 | *

99 | * This is used to request an action from the server which requires server-side information. 100 | * @constructor 101 | * @param request This request 102 | * @param message The message accompanying this request 103 | */ 104 | ServerQueryMessage: function(request, message) { 105 | this.request = request; 106 | this.message = message; 107 | 108 | this.toString = function() { 109 | return "ServerQueryMessage: Request" + this.request + " message: " + this.message; 110 | }; 111 | }, 112 | 113 | 114 | /** 115 | * Request to start a new game. 116 | *

117 | * This is sent from the Client to the Server when this player invites another player (including AI) to start a new game of a chosen type. 118 | * @constructor 119 | * @param opponent The Id of the player entity being invited by this player 120 | * @param gameType The type / mod of the game chosen by this player 121 | */ 122 | StartGameRequest: function(opponent, gameType) { 123 | this.opponent = opponent; 124 | this.gameType = gameType; 125 | }, 126 | 127 | /** 128 | * Serialize message from JSON to byte. 129 | *

130 | * Primarily used for libGDX client. 131 | * Constructor. 132 | * @param type This message type 133 | */ 134 | TransformerMessage: function(type) { 135 | this.type = type; 136 | }, 137 | 138 | /** 139 | * Message for a game entity to use a certain ability. 140 | *

141 | * Game entities (e.g., cards, players) may have one or more ability actions that they can perform. 142 | * Certain abilities can have multiple targets, hence the use of an array. 143 | * @constructor. (multiple targets) 144 | *

145 | * Used for multiple target actions. 146 | * 147 | * @param gameId This current game 148 | * @param entity This game entity performing an action 149 | * @param action This action 150 | * @param targets The set of multiple targets affected by this action 151 | */ 152 | UseAbilityMessage: function(gameId, id, action, targets) { 153 | this.gameId = gameId; 154 | this.id = id; 155 | this.action = action; 156 | this.targets = targets; 157 | 158 | this.toString = function() { 159 | return "UseAbilityMessage" + 160 | "[id=" + this.id + 161 | ", action=" + this.action + 162 | ", gameId=" + this.gameId + 163 | ", targets=" + this.targets.toString() + 164 | "]"; 165 | }; 166 | }, 167 | 168 | /** 169 | * Chat message in game lobby. 170 | *

171 | * These are messages printed to the game lobby which are visible to all users present at the time the message is posted. 172 | * @constructor 173 | * @param message The content of this chat message 174 | */ 175 | ChatMessage: function(message) { 176 | this.chatId = MAIN_LOBBY; 177 | this.message = message; 178 | 179 | this.toString = function() { 180 | return "ChatMessage [chatId=" + chatId + ", message=" + message + ", from=" + from + "]"; 181 | }; 182 | }, 183 | 184 | /** 185 | * Request to invite a player to start a new game. 186 | * @constructor 187 | * @param id The Id of this invite request 188 | * @param name The name of the player being invited 189 | * @param gameType The game type of this invite request 190 | */ 191 | InviteRequest: function(id, name, gameType) { 192 | this.id = id; 193 | this.name = name; 194 | this.gameType = gameType; 195 | }, 196 | 197 | /** 198 | * Response to an InviteRequest message. 199 | * @constructor 200 | * @param inviteId Id of this incoming InviteRequest message 201 | * @param accepted Whether or not the InviteRequest is accepted 202 | */ 203 | InviteResponse: function(inviteId, accepted) { 204 | this.inviteId = inviteId; 205 | this.accepted = accepted; 206 | }, 207 | 208 | /** 209 | * Player configuration for a given game. 210 | * @constructor 211 | * @param gameId This game 212 | * @param modName The mod name for this game 213 | * @param configs Map of player name and applicable player configuration 214 | */ 215 | PlayerConfigMessage: function(gameId, modName, configs) { 216 | this.gameId = gameId; 217 | this.modName = modName; 218 | this.configs = configs; 219 | 220 | this.toString = function() { 221 | return "PlayerConfigMessage{" + 222 | "configs=" + configs + 223 | ", gameId=" + gameId + 224 | ", modName='" + modName + '\'' + 225 | '}'; 226 | }; 227 | } 228 | } 229 | }; 230 | }, 231 | methods: { 232 | 233 | /** 234 | * Initializes the API for use. 235 | * 236 | * @param server:string -- The server that to be connected to. 237 | * @param isSecure:boolean -- Whether or not the server is being connected to with wss 238 | * 239 | * This sets up all the message types to inherit the main `Message` class, and sets 240 | * up the websocket that will be used to communicate to the server, and to recieve 241 | * information from the server. 242 | * 243 | */ 244 | init(server, isSecure, onReady, onError) { 245 | var types = this.messageTypes; 246 | 247 | types.LoginMessage.prototype = new Message("login"); 248 | types.RequestTargetsMessage.prototype = new Message("requestTargets"); 249 | types.ServerQueryMessage.prototype = new Message("query"); 250 | types.StartGameRequest.prototype = new Message("startgame"); 251 | types.TransformerMessage.prototype = new Message("serial"); 252 | types.UseAbilityMessage.prototype = new Message("use"); 253 | types.ChatMessage.prototype = new Message("chat"); 254 | types.InviteRequest.prototype = new Message("inviteRequest"); 255 | types.InviteResponse.prototype = new Message("inviteResponse"); 256 | types.PlayerConfigMessage.prototype = new Message("playerconfig"); 257 | NotInitializedException.prototype = new Error(); 258 | SocketNotReadyException.prototype = new Error(); 259 | 260 | // secure websocket is wss://, rather than ws:// 261 | var secureAddon = (isSecure ? "s" : ""); 262 | // if the protocol is not found in the string, store the correct protocol (is secure?) 263 | var protocolAddon = (wsProtocolFinder.test(server) ? "" : "ws" + secureAddon + "://"); 264 | var socket = new WebSocket(protocolAddon + server); 265 | 266 | socket.onopen = onReady; 267 | socket.onmessage = this.recieve; 268 | 269 | socket.onerror = function() { 270 | onError(); 271 | this.socket = null; 272 | } 273 | 274 | this.socket = socket; 275 | }, 276 | 277 | recieve(message) { 278 | var data = JSON.parse(message.data); 279 | var command = data.command; 280 | console.log("Message received: " + JSON.stringify(data)); 281 | this.$emit(`type:${data.command}`, data); 282 | }, 283 | 284 | /** 285 | * Sends a message to the server 286 | * 287 | * @param message:Message -- The message to send 288 | * @error SocketNotReadyException -- The socket is not ready to be used 289 | * @error NotInitializedException -- The API has not yet been initialized 290 | */ 291 | sendMessage(message) { 292 | var socket = this.socket; 293 | if (socket) { 294 | if (socket.readyState === SOCKET_OPEN) { 295 | let msgData = JSON.stringify(flatten(message)); 296 | this.socket.send(msgData); 297 | console.log("Sending to server: " + msgData); 298 | } else { 299 | throw new SocketNotReadyException("The Websocket is not ready to be used.", socket.readyState); 300 | } 301 | } else { 302 | throw new NotInitializedException("The API has not yet been initialized."); 303 | } 304 | } 305 | } 306 | }); 307 | 308 | export default CardshifterServerAPI; 309 | -------------------------------------------------------------------------------- /static/.gitkeep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Cardshifter/HTML-Client/99ad977f831cd9991b9158fd7c8c3ca97cadc1a9/static/.gitkeep -------------------------------------------------------------------------------- /test/unit/.eslintrc: -------------------------------------------------------------------------------- 1 | { 2 | "env": { 3 | "mocha": true 4 | }, 5 | "globals": { 6 | "expect": true, 7 | "sinon": true 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /test/unit/index.js: -------------------------------------------------------------------------------- 1 | import Vue from 'vue' 2 | 3 | Vue.config.productionTip = false 4 | 5 | // require all test files (files that ends with .spec.js) 6 | const testsContext = require.context('./specs', true, /\.spec$/) 7 | testsContext.keys().forEach(testsContext) 8 | 9 | // require all src files except main.js for coverage. 10 | // you can also change this to match only the subset of files that 11 | // you want coverage for. 12 | const srcContext = require.context('../../src', true, /^\.\/(?!main(\.js)?$)/) 13 | srcContext.keys().forEach(srcContext) 14 | -------------------------------------------------------------------------------- /test/unit/karma.conf.js: -------------------------------------------------------------------------------- 1 | // This is a karma config file. For more details see 2 | // http://karma-runner.github.io/0.13/config/configuration-file.html 3 | // we are also using it with karma-webpack 4 | // https://github.com/webpack/karma-webpack 5 | 6 | var webpackConfig = require('../../build/webpack.test.conf') 7 | 8 | module.exports = function karmaConfig (config) { 9 | config.set({ 10 | // to run in additional browsers: 11 | // 1. install corresponding karma launcher 12 | // http://karma-runner.github.io/0.13/config/browsers.html 13 | // 2. add it to the `browsers` array below. 14 | browsers: ['PhantomJS'], 15 | frameworks: ['mocha', 'sinon-chai', 'phantomjs-shim'], 16 | reporters: ['spec', 'coverage'], 17 | files: ['./index.js'], 18 | preprocessors: { 19 | './index.js': ['webpack', 'sourcemap'] 20 | }, 21 | webpack: webpackConfig, 22 | webpackMiddleware: { 23 | noInfo: true 24 | }, 25 | coverageReporter: { 26 | dir: './coverage', 27 | reporters: [ 28 | { type: 'lcov', subdir: '.' }, 29 | { type: 'text-summary' } 30 | ] 31 | } 32 | }) 33 | } 34 | -------------------------------------------------------------------------------- /test/unit/specs/HelloWorld.spec.js: -------------------------------------------------------------------------------- 1 | import Vue from 'vue' 2 | import HelloWorld from '@/components/HelloWorld' 3 | 4 | describe('HelloWorld.vue', () => { 5 | it('should render correct contents', () => { 6 | const Constructor = Vue.extend(HelloWorld) 7 | const vm = new Constructor().$mount() 8 | expect(vm.$el.querySelector('.hello h1').textContent) 9 | .to.equal('Welcome to Your Vue.js App') 10 | }) 11 | }) 12 | --------------------------------------------------------------------------------