├── .browserslistrc
├── .editorconfig
├── .gitignore
├── LICENSE.txt
├── README.md
├── angular.json
├── design
├── copyright.psd
├── logo.psd
├── logo_base.psd
└── logo_base_apple.psd
├── docs
├── assets
│ ├── favicon.ico
│ └── images
│ │ ├── particle-template
│ │ ├── basic.png
│ │ ├── blue_light.png
│ │ ├── commet.png
│ │ ├── fire.png
│ │ ├── graphic.png
│ │ ├── green_kirakira.png
│ │ ├── heart_world.png
│ │ ├── light_ball.png
│ │ ├── parple.png
│ │ ├── snow.png
│ │ ├── spirit.png
│ │ └── star.png
│ │ ├── preview.png
│ │ └── ui
│ │ ├── about.png
│ │ ├── copyright.png
│ │ ├── logo.png
│ │ ├── logo_512x512.png
│ │ ├── logo_angular2.png
│ │ ├── logo_base_apple.png
│ │ └── logo_createjs.svg
├── fontawesome-webfont.1e59d2330b4c6deb84b3.ttf
├── fontawesome-webfont.20fd1704ea223900efa9.woff2
├── fontawesome-webfont.8b43027f47b20503057d.eot
├── fontawesome-webfont.c1e38fd9e0e74ba58f7a.svg
├── fontawesome-webfont.f691f37e57f04c152e23.woff
├── index.html
├── main.91cb2af579221e8d3777.js
├── manifest.json
├── md-arrow-dropdown.01c07968ec11e6415f1a.svg
├── polyfills-es5.111f0e5c86603dab3f32.js
├── polyfills.df86bdad99f68d243eb9.js
├── runtime.327421ac618f30d8146f.js
├── scripts.56481d7eb9031ad1f86e.js
├── service-worker.js
└── styles.517fcad9028b7a83fc5e.js
├── package.json
├── src
├── app
│ ├── app.module.ts
│ ├── assets
│ │ └── particle-parameter.ts
│ ├── components
│ │ ├── app
│ │ │ ├── app.component.html
│ │ │ ├── app.component.scss
│ │ │ └── app.component.ts
│ │ ├── footer
│ │ │ ├── footer.component.html
│ │ │ ├── footer.component.scss
│ │ │ └── footer.component.ts
│ │ ├── header-desktop
│ │ │ ├── header-desktop.component.html
│ │ │ ├── header-desktop.component.scss
│ │ │ └── header-desktop.component.ts
│ │ ├── header-mobile
│ │ │ ├── header-mobile.component.html
│ │ │ ├── header-mobile.component.scss
│ │ │ └── header-mobile.component.ts
│ │ ├── input-range
│ │ │ ├── input-range.component.html
│ │ │ └── input-range.component.ts
│ │ ├── modal-export-json
│ │ │ ├── modal-export-json.component.html
│ │ │ ├── modal-export-json.component.scss
│ │ │ └── modal-export-json.component.ts
│ │ ├── modal-template
│ │ │ ├── modal-template.component.html
│ │ │ ├── modal-template.component.scss
│ │ │ └── modal-template.component.ts
│ │ ├── properties
│ │ │ ├── property-canvas
│ │ │ │ ├── property-canvas.component.html
│ │ │ │ ├── property-canvas.component.scss
│ │ │ │ └── property-canvas.component.ts
│ │ │ ├── property-color
│ │ │ │ ├── property-color-unit.component.html
│ │ │ │ ├── property-color-unit.component.scss
│ │ │ │ ├── property-color-unit.component.ts
│ │ │ │ ├── property-color.component.html
│ │ │ │ ├── property-color.component.scss
│ │ │ │ └── property-color.component.ts
│ │ │ ├── property-emitter
│ │ │ │ ├── property-emitter.component.html
│ │ │ │ └── property-emitter.component.ts
│ │ │ ├── property-particle
│ │ │ │ ├── property-particle.component.html
│ │ │ │ └── property-particle.component.ts
│ │ │ ├── property-shape
│ │ │ │ ├── property-shape-itemrenderer.component.html
│ │ │ │ ├── property-shape-itemrenderer.component.ts
│ │ │ │ ├── property-shape.component.html
│ │ │ │ ├── property-shape.component.scss
│ │ │ │ └── property-shape.component.ts
│ │ │ ├── property-template
│ │ │ │ ├── property-template.component.html
│ │ │ │ ├── property-template.component.scss
│ │ │ │ └── property-template.component.ts
│ │ │ ├── property.component.html
│ │ │ ├── property.component.scss
│ │ │ └── property.component.ts
│ │ └── stage
│ │ │ └── stage.component.ts
│ ├── data
│ │ └── platform-data.ts
│ ├── enum
│ │ ├── canvas-margin.ts
│ │ ├── platform-type.ts
│ │ └── view-port.ts
│ ├── i18n
│ │ ├── locale-data.ts
│ │ ├── locale-en.ts
│ │ ├── locale-ja.ts
│ │ └── locale-manager.ts
│ └── particle
│ │ ├── particle-canvas.ts
│ │ ├── particle-capture-image-layer.ts
│ │ ├── particle-exporter.ts
│ │ ├── particle-image-importer.ts
│ │ └── particle-ruler.ts
├── assets
│ ├── favicon.ico
│ └── images
│ │ ├── particle-template
│ │ ├── basic.png
│ │ ├── blue_light.png
│ │ ├── commet.png
│ │ ├── fire.png
│ │ ├── graphic.png
│ │ ├── green_kirakira.png
│ │ ├── heart_world.png
│ │ ├── light_ball.png
│ │ ├── parple.png
│ │ ├── snow.png
│ │ ├── spirit.png
│ │ └── star.png
│ │ ├── preview.png
│ │ └── ui
│ │ ├── about.png
│ │ ├── copyright.png
│ │ ├── logo.png
│ │ ├── logo_512x512.png
│ │ ├── logo_angular2.png
│ │ ├── logo_base_apple.png
│ │ └── logo_createjs.svg
├── embeds
│ ├── images
│ │ └── md-arrow-dropdown.svg
│ ├── js
│ │ ├── 1.0.0
│ │ │ └── createjs.min.js
│ │ ├── SVGExporter.js
│ │ └── particlejs.min.js
│ ├── topcoat
│ │ └── topcoat-desktop-dark.custom.css
│ └── typings
│ │ ├── index.d.ts
│ │ └── other
│ │ └── index.d.ts
├── environments
│ ├── environment.prod.ts
│ └── environment.ts
├── index.html
├── main.ts
├── polyfills.ts
├── pwa
│ ├── manifest.json
│ └── service-worker.js
├── scss
│ ├── .csscomb.json
│ ├── .scss-lint.yml
│ └── ics
│ │ ├── _variables.scss
│ │ └── particledevelop.scss
├── styles.scss
├── tsconfig.app.json
└── typings.d.ts
├── tsconfig.base.json
├── tsconfig.json
└── tslint.json
/.browserslistrc:
--------------------------------------------------------------------------------
1 | # This file is used by the build system to adjust CSS and JS output to support the specified browsers below.
2 | # For additional information regarding the format and rule options, please see:
3 | # https://github.com/browserslist/browserslist#queries
4 |
5 | # For the full list of supported browsers by the Angular framework, please see:
6 | # https://angular.io/guide/browser-support
7 |
8 | # You can see what browsers were selected by your queries by running:
9 | # npx browserslist
10 |
11 | last 1 Chrome version
12 | last 1 Firefox version
13 | last 2 Edge major versions
14 | last 2 Safari major versions
15 | last 2 iOS major versions
16 | Firefox ESR
17 | not IE 9-10 # Angular support for IE 9-10 has been deprecated and will be removed as of Angular v11. To opt-in, remove the 'not' prefix on this line.
18 | IE 11 # Angular supports IE 11 only as an opt-in. To opt-in, remove the 'not' prefix on this line.
19 |
--------------------------------------------------------------------------------
/.editorconfig:
--------------------------------------------------------------------------------
1 | # Editor configuration, see http://editorconfig.org
2 | root = true
3 |
4 | [*]
5 | charset = utf-8
6 | indent_style = space
7 | indent_size = 2
8 | insert_final_newline = true
9 | trim_trailing_whitespace = true
10 |
11 | [*.md]
12 | max_line_length = off
13 | trim_trailing_whitespace = false
14 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | # See http://help.github.com/ignore-files/ for more about ignoring files.
2 |
3 | # compiled output
4 | /dist
5 | /tmp
6 | /out-tsc
7 |
8 | # dependencies
9 | /node_modules
10 |
11 | # IDEs and editors
12 | /.idea
13 | .project
14 | .classpath
15 | .c9/
16 | !typings
17 | *.launch
18 | .settings/
19 | *.sublime-workspace
20 |
21 | # IDE - VSCode
22 | .vscode/*
23 | !.vscode/settings.json
24 | !.vscode/tasks.json
25 | !.vscode/launch.json
26 | !.vscode/extensions.json
27 |
28 | # misc
29 | /.sass-cache
30 | /connect.lock
31 | /coverage
32 | /libpeerconnection.log
33 | npm-debug.log
34 | testem.log
35 |
36 | # e2e
37 | /e2e/*.js
38 | /e2e/*.map
39 |
40 | *.js*.map
41 |
42 | # System Files
43 | .DS_Store
44 | Thumbs.db
45 | /package-lock.json
46 | /yarn.lock
47 | /Icon
48 |
--------------------------------------------------------------------------------
/LICENSE.txt:
--------------------------------------------------------------------------------
1 | The MIT License (MIT)
2 |
3 | Copyright (c) 2016 ICS INC.
4 |
5 | Permission is hereby granted, free of charge, to any person obtaining a copy
6 | of this software and associated documentation files (the "Software"), to deal
7 | in the Software without restriction, including without limitation the rights
8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9 | copies of the Software, and to permit persons to whom the Software is
10 | furnished to do so, subject to the following conditions:
11 |
12 | The above copyright notice and this permission notice shall be included in all
13 | copies or substantial portions of the Software.
14 |
15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21 | SOFTWARE.
22 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # Particle Develop
2 |
3 | 
4 |
5 | ## Description
6 |
7 | Particle DevelopはHTML5製のデザインツールです。雪や炎、キラキラなどのパーティクル表現を作成でき、ベクター画像として保存することができます。Adobe Illustratorのイラスト制作にも役立ちます。
8 |
9 | ## Version History
10 |
11 | ### Particle Develop 3.4, 2020/07/12
12 |
13 | - Migration Angular 8.1 -> 10
14 | - BugFix
15 | - License Field is changed
16 |
17 | ### Particle Develop 3.3, 2019/07/29
18 |
19 | - Migration Angular 6.0 -> 8.1
20 | - BugFix
21 |
22 | ### Particle Develop 3.2, 2018/05/31
23 | https://ics-creative.github.io/project-particle-develop/
24 |
25 | - apply `https` protocol
26 | - Move domain from `ics-web.jp` to `ics-creative.github.io`
27 | - Migration Angular 6.0
28 |
29 | ### Particle Develop 3.0, 2018/04/16
30 | http://ics-web.jp/projects/particle-develop-3.0/
31 |
32 | - Migration Angular 4 -> 5.2
33 | - Using Angular-CLI 6.0.0-rc.2
34 |
35 | ### Version 2.5, 2018/04/11
36 | http://ics-web.jp/projects/particle-develop-2.5/
37 |
38 | - BugFix for saving image file on Chrome
39 |
40 | ### Version 2.0, 2017/06/14
41 | http://ics-web.jp/projects/particle-develop-2.0/
42 |
43 | - Migration Angular 2 -> 4
44 | - Using Angular-CLI 1.0
45 |
46 |
47 | ### Version 1.0, 2016/03/10
48 |
49 | http://ics-web.jp/projects/particle-develop-1.0/
50 |
51 | - initial version
52 |
53 | ## Copyright
54 |
55 | (C) 2016-2020 ICS INC. All Rights Resserved.
56 |
--------------------------------------------------------------------------------
/angular.json:
--------------------------------------------------------------------------------
1 | {
2 | "version": 1,
3 | "newProjectRoot": "projects",
4 | "projects": {
5 | "ParticleDevelop": {
6 | "root": "",
7 | "projectType": "application",
8 | "architect": {
9 | "build": {
10 | "builder": "@angular-devkit/build-angular:browser",
11 | "options": {
12 | "aot": true,
13 | "outputPath": "docs",
14 | "index": "src/index.html",
15 | "main": "src/main.ts",
16 | "tsConfig": "src/tsconfig.app.json",
17 | "polyfills": "src/polyfills.ts",
18 | "assets": [
19 | {
20 | "glob": "**/*",
21 | "input": "src/assets",
22 | "output": "/assets"
23 | },
24 | {
25 | "glob": "**/*",
26 | "input": "src/pwa",
27 | "output": "."
28 | }
29 | ],
30 | "styles": [
31 | {
32 | "input": "src/styles.scss"
33 | }
34 | ],
35 | "scripts": [
36 | {
37 | "input": "src/embeds/js/1.0.0/createjs.min.js"
38 | },
39 | {
40 | "input": "src/embeds/js/SVGExporter.js"
41 | }
42 | ]
43 | },
44 | "configurations": {
45 | "production": {
46 | "budgets": [
47 | {
48 | "type": "anyComponentStyle",
49 | "maximumWarning": "6kb"
50 | }
51 | ],
52 | "optimization": true,
53 | "outputHashing": "all",
54 | "sourceMap": false,
55 | "extractCss": false,
56 | "namedChunks": false,
57 | "aot": true,
58 | "extractLicenses": false,
59 | "vendorChunk": false,
60 | "buildOptimizer": true,
61 | "fileReplacements": [
62 | {
63 | "src": "src/environments/environment.ts",
64 | "replaceWith": "src/environments/environment.prod.ts"
65 | }
66 | ]
67 | }
68 | }
69 | },
70 | "serve": {
71 | "builder": "@angular-devkit/build-angular:dev-server",
72 | "options": {
73 | "browserTarget": "ParticleDevelop:build"
74 | },
75 | "configurations": {
76 | "production": {
77 | "browserTarget": "ParticleDevelop:build:production"
78 | }
79 | }
80 | },
81 | "extract-i18n": {
82 | "builder": "@angular-devkit/build-angular:extract-i18n",
83 | "options": {
84 | "browserTarget": "ParticleDevelop:build"
85 | }
86 | },
87 | "lint": {
88 | "builder": "@angular-devkit/build-angular:tslint",
89 | "options": {
90 | "tsConfig": [
91 | "src/tsconfig.app.json"
92 | ],
93 | "exclude": []
94 | }
95 | }
96 | }
97 | }
98 | },
99 | "schematics": {
100 | "@schematics/angular:component": {
101 | "prefix": "app",
102 | "style": "scss"
103 | },
104 | "@schematics/angular:directive": {
105 | "prefix": "app"
106 | }
107 | }
108 | }
109 |
--------------------------------------------------------------------------------
/design/copyright.psd:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/design/copyright.psd
--------------------------------------------------------------------------------
/design/logo.psd:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/design/logo.psd
--------------------------------------------------------------------------------
/design/logo_base.psd:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/design/logo_base.psd
--------------------------------------------------------------------------------
/design/logo_base_apple.psd:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/design/logo_base_apple.psd
--------------------------------------------------------------------------------
/docs/assets/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/docs/assets/favicon.ico
--------------------------------------------------------------------------------
/docs/assets/images/particle-template/basic.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/docs/assets/images/particle-template/basic.png
--------------------------------------------------------------------------------
/docs/assets/images/particle-template/blue_light.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/docs/assets/images/particle-template/blue_light.png
--------------------------------------------------------------------------------
/docs/assets/images/particle-template/commet.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/docs/assets/images/particle-template/commet.png
--------------------------------------------------------------------------------
/docs/assets/images/particle-template/fire.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/docs/assets/images/particle-template/fire.png
--------------------------------------------------------------------------------
/docs/assets/images/particle-template/graphic.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/docs/assets/images/particle-template/graphic.png
--------------------------------------------------------------------------------
/docs/assets/images/particle-template/green_kirakira.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/docs/assets/images/particle-template/green_kirakira.png
--------------------------------------------------------------------------------
/docs/assets/images/particle-template/heart_world.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/docs/assets/images/particle-template/heart_world.png
--------------------------------------------------------------------------------
/docs/assets/images/particle-template/light_ball.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/docs/assets/images/particle-template/light_ball.png
--------------------------------------------------------------------------------
/docs/assets/images/particle-template/parple.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/docs/assets/images/particle-template/parple.png
--------------------------------------------------------------------------------
/docs/assets/images/particle-template/snow.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/docs/assets/images/particle-template/snow.png
--------------------------------------------------------------------------------
/docs/assets/images/particle-template/spirit.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/docs/assets/images/particle-template/spirit.png
--------------------------------------------------------------------------------
/docs/assets/images/particle-template/star.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/docs/assets/images/particle-template/star.png
--------------------------------------------------------------------------------
/docs/assets/images/preview.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/docs/assets/images/preview.png
--------------------------------------------------------------------------------
/docs/assets/images/ui/about.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/docs/assets/images/ui/about.png
--------------------------------------------------------------------------------
/docs/assets/images/ui/copyright.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/docs/assets/images/ui/copyright.png
--------------------------------------------------------------------------------
/docs/assets/images/ui/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/docs/assets/images/ui/logo.png
--------------------------------------------------------------------------------
/docs/assets/images/ui/logo_512x512.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/docs/assets/images/ui/logo_512x512.png
--------------------------------------------------------------------------------
/docs/assets/images/ui/logo_angular2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/docs/assets/images/ui/logo_angular2.png
--------------------------------------------------------------------------------
/docs/assets/images/ui/logo_base_apple.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/docs/assets/images/ui/logo_base_apple.png
--------------------------------------------------------------------------------
/docs/assets/images/ui/logo_createjs.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
54 |
--------------------------------------------------------------------------------
/docs/fontawesome-webfont.1e59d2330b4c6deb84b3.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/docs/fontawesome-webfont.1e59d2330b4c6deb84b3.ttf
--------------------------------------------------------------------------------
/docs/fontawesome-webfont.20fd1704ea223900efa9.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/docs/fontawesome-webfont.20fd1704ea223900efa9.woff2
--------------------------------------------------------------------------------
/docs/fontawesome-webfont.8b43027f47b20503057d.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/docs/fontawesome-webfont.8b43027f47b20503057d.eot
--------------------------------------------------------------------------------
/docs/fontawesome-webfont.f691f37e57f04c152e23.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/docs/fontawesome-webfont.f691f37e57f04c152e23.woff
--------------------------------------------------------------------------------
/docs/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | HTML5製のデザインツール Particle Develop - ICS
6 |
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 |
106 |
107 |
108 |
109 |
110 |
111 | Particle Develop
112 | LOADING...
113 |
114 |
115 |
116 |
117 |
118 |
119 |
120 |
132 |
133 |
134 |
--------------------------------------------------------------------------------
/docs/manifest.json:
--------------------------------------------------------------------------------
1 | {
2 | "short_name": "Particle Develop",
3 | "name": "Particle Develop",
4 | "icons": [
5 | {
6 | "src": "./assets/images/ui/logo_512x512.png",
7 | "type": "image/png",
8 | "sizes": "512x512"
9 | }
10 | ],
11 | "start_url": "index.html?homescreen=1",
12 | "display": "standalone",
13 | "background_color": "#222222",
14 | "theme_color": "#222222"
15 | }
16 |
--------------------------------------------------------------------------------
/docs/md-arrow-dropdown.01c07968ec11e6415f1a.svg:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/docs/runtime.327421ac618f30d8146f.js:
--------------------------------------------------------------------------------
1 | !function(e){function r(r){for(var n,l,f=r[0],i=r[1],p=r[2],c=0,s=[];c
2 |
29 |
30 |
33 |
34 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
55 |
56 |
{{localeData.MA_sentence}}
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
69 |
70 |
71 |
72 |
75 |
76 |
--------------------------------------------------------------------------------
/src/app/components/app/app.component.scss:
--------------------------------------------------------------------------------
1 | $grid-breakpoints: (
2 | xs: 0,
3 | sm: 576px,
4 | md: 768px,
5 | lg: 992px,
6 | xl: 1200px
7 | ) !default;
8 |
9 | .pd {
10 | width: 100%;
11 | height: 100%;
12 | display: grid;
13 |
14 | grid-template-columns: 1fr 350px;
15 | grid-template-rows: 50px 1fr 40px;
16 | grid-template-areas: 'header header' 'canvas property' 'footer footer';
17 |
18 | @media (max-width: map-get($grid-breakpoints, "md")) {
19 | grid-template-columns: 1fr;
20 | grid-template-rows: 50px 1fr 40px;
21 | grid-template-areas: 'header' 'canvas' 'footer';
22 | }
23 |
24 | &-header {
25 | grid-area: header;
26 | }
27 | &-canvas {
28 | grid-area: canvas;
29 | background-color: #222222;
30 | overflow: hidden;
31 | }
32 | &-property {
33 | grid-area: property;
34 |
35 | @media (max-width: map-get($grid-breakpoints, "md")) {
36 | display: none;
37 | }
38 | }
39 | &-footer {
40 | grid-area: footer;
41 | display: flex;
42 | justify-content: center;
43 | align-items: center;
44 | }
45 |
46 | }
47 |
48 |
49 |
50 | .pd-header {
51 | background-color: theme-color("primary");
52 |
53 | border-bottom: 1px solid #000000;
54 |
55 | &__grid {
56 | display: grid;
57 |
58 | grid-template-columns: 226px auto 1fr;
59 | grid-template-rows: 49px;
60 | grid-template-areas: "logo about menu";
61 |
62 | @media (max-width: map-get($grid-breakpoints, "sm")) {
63 | grid-template-columns: auto 1fr;
64 | grid-template-rows: 49px;
65 | grid-template-areas: "logo menu";
66 | }
67 |
68 | &-logo {
69 | grid-area: logo;
70 | }
71 | &-about {
72 | grid-area: about;
73 | }
74 | &-menu {
75 | grid-area: menu;
76 | }
77 | }
78 |
79 | li {
80 | list-style: none;
81 | }
82 |
83 |
84 | h1 {
85 | padding: 3px 10px 0;
86 | margin: 0;
87 | line-height: 1.0;
88 | font-size: 1.0rem;
89 | height: 49px;
90 | display: flex;
91 | align-items: center;
92 | }
93 |
94 | .header-desktop-menu {
95 | margin-left: auto;
96 | margin-right: 0;
97 | text-align: right;
98 | display: block;
99 | }
100 |
101 | .header-mobile-menu ul {
102 | padding-left: 0;
103 | li {
104 | box-sizing: border-box;
105 | .btn {
106 | font-size: rem-calc(16);
107 | padding: 5px 15px 6px;
108 | }
109 | }
110 | }
111 | }
112 |
113 | ::ng-deep .header-btn {
114 | line-height: 49px;
115 | height: 49px;
116 | border-top: none;
117 | border-bottom: none;
118 | padding-top: 0;
119 | padding-bottom: 0;
120 | background-color: inherit;
121 | color: #cccccc;
122 | }
123 |
--------------------------------------------------------------------------------
/src/app/components/app/app.component.ts:
--------------------------------------------------------------------------------
1 | import {AfterViewInit, Component, ViewChild} from '@angular/core';
2 | import {DrawingData, VERSION} from 'particlejs';
3 | import {PlatformData} from '../../data/platform-data';
4 | import {CanvasMargin} from '../../enum/canvas-margin';
5 | import {PlatformType} from '../../enum/platform-type';
6 | import {Viewport} from '../../enum/view-port';
7 | import {LocaleData} from '../../i18n/locale-data';
8 | import {LocaleManager} from '../../i18n/locale-manager';
9 | import {ModalExportJsonComponent} from '../modal-export-json/modal-export-json.component';
10 | import {StageComponent} from '../stage/stage.component';
11 |
12 | @Component({
13 | selector : 'app-root',
14 | templateUrl: './app.component.html',
15 | styleUrls : ['./app.component.scss'],
16 | providers : [LocaleData],
17 | })
18 |
19 | export class AppComponent implements AfterViewInit {
20 | drawingData: DrawingData;
21 | platformData: PlatformData;
22 | @ViewChild('stageComponent', { static: true }) stageComponent!: StageComponent;
23 | @ViewChild('propetyModal', { static: true }) propetyModal!: ModalExportJsonComponent;
24 |
25 | getPlatformData() {
26 | return new PlatformData(PlatformType.Browser);
27 | }
28 |
29 | constructor(public localeData: LocaleData) {
30 | this.drawingData = new DrawingData();
31 | this.platformData = this.getPlatformData();
32 |
33 | // ステージサイズに対して適当な値を適用する
34 |
35 | let canvasWidth: number = innerWidth;
36 | let canvasHeight: number = innerHeight;
37 |
38 | if (innerWidth > Viewport.sm) {
39 | canvasHeight -= CanvasMargin.TOP_DESKTOP;
40 | canvasWidth -= CanvasMargin.RIGHT_DESKTOP;
41 | } else {
42 | canvasHeight -= CanvasMargin.TOP_MOBILE;
43 | canvasWidth -= CanvasMargin.RIGHT_MOBILE;
44 | }
45 |
46 | const sw = Math.round(canvasWidth * 2 / 3);
47 | const sh = Math.round(canvasHeight * 2 / 3);
48 |
49 | this.drawingData.startX = Math.round(sw / 2);
50 | this.drawingData.startY = Math.round(sh / 2);
51 | this.drawingData.width = sw;
52 | this.drawingData.height = sh;
53 |
54 | new LocaleManager().applyClientLocale(localeData);
55 | }
56 |
57 | ngAfterViewInit() {
58 | const lang = new LocaleManager().checkLocale();
59 |
60 | if (lang !== 'ja') {
61 | document.title = 'Particle Develop - HTML5 Vector Design Tool - ICS';
62 | }
63 |
64 | if (!lang) {
65 | return;
66 | }
67 | this.setupWidgets(lang);
68 | }
69 |
70 | protected setupWidgets(lang: string) {
71 | const langLong = lang === 'ja' ? 'ja_JP' : 'en_EN';
72 |
73 | (function (d: Document, s: string, id: string) {
74 | let js: HTMLScriptElement;
75 | const fjs = d.getElementsByTagName(s)[0];
76 | if (d.getElementById(id)) {
77 | return;
78 | }
79 | js = d.createElement(s);
80 | js.id = id;
81 | js.src = 'https://b.st-hatena.com/js/bookmark_button.js';
82 | if (fjs.parentNode) {
83 | fjs.parentNode.insertBefore(js, fjs);
84 | }
85 | }(document, 'script', 'hatena'));
86 |
87 | (function (d: any, s: string, id: string) {
88 | let js: HTMLScriptElement;
89 | const fjs = d.getElementsByTagName(s)[0];
90 | const p = /^http:/.test(d.location) ? 'http' : 'https';
91 | if (!d.getElementById(id)) {
92 | js = d.createElement(s);
93 | js.id = id;
94 | js.src = p + '://platform.twitter.com/widgets.js';
95 | fjs.parentNode.insertBefore(js, fjs);
96 | }
97 | }(document, 'script', 'twitter-wjs'));
98 |
99 | (function (d: Document, s: string, id: string) {
100 | let js: HTMLScriptElement;
101 | const fjs = d.getElementsByTagName(s)[0];
102 | if (d.getElementById(id)) {
103 | return;
104 | }
105 | js = d.createElement(s);
106 | js.id = id;
107 | js.src = `//connect.facebook.net/${langLong}/sdk.js#xfbml=1&version=v2.5&appId=566926136738876`;
108 | if (fjs.parentNode) {
109 | fjs.parentNode.insertBefore(js, fjs);
110 | }
111 | }(document, 'script', 'facebook-jssdk'));
112 | }
113 |
114 | public handleSvgClick() {
115 | this.stageComponent.exportSvg().then(() => {
116 | this.openSvgExportWindow();
117 | });
118 | }
119 |
120 | private convertBlobFromBase64(base64: string, mimeType: string): Blob {
121 | const bin = atob(base64.replace(/^.*,/, ''));
122 | const buffer = new Uint8Array(bin.length);
123 | for (let i = 0; i < bin.length; i++) {
124 | buffer[i] = bin.charCodeAt(i);
125 | }
126 |
127 | // Blobを作成
128 | const blob = new Blob([buffer.buffer], {
129 | type: mimeType,
130 | });
131 | return blob;
132 | }
133 |
134 | private saveFile(base64: string,
135 | fileName: string,
136 | mimeType: string): void {
137 | const blob = this.convertBlobFromBase64(base64, mimeType);
138 |
139 | if (window.navigator.msSaveBlob) {
140 | // for IE
141 | window.navigator.msSaveBlob(blob, fileName);
142 | } else if (window.URL && window.URL.createObjectURL) {
143 | // for Firefox, Chrome, Safari
144 | const a = document.createElement('a');
145 | a.download = fileName;
146 | a.href = window.URL.createObjectURL(blob);
147 | document.body.appendChild(a);
148 | a.click();
149 | document.body.removeChild(a);
150 | } else {
151 | // for Other
152 | window.open(base64, '_blank');
153 | }
154 | }
155 |
156 | public handleJpgClick() {
157 | const dataUrl = this.stageComponent.toDataURL('image/jpeg', '1.0');
158 |
159 | this.saveFile(dataUrl, `particle_${Math.round(Date.now() / 1000)}.jpg`, 'image/jpeg');
160 | }
161 |
162 | public handlePngClick() {
163 | const dataUrl = this.stageComponent.toDataURL('image/png', '');
164 |
165 | this.saveFile(dataUrl, `particle_${Math.round(Date.now() / 1000)}.png`, 'image/png');
166 | }
167 |
168 | public handleWebpClick() {
169 | const dataUrl = this.stageComponent.toDataURL('image/webp', '');
170 |
171 | this.saveFile(dataUrl, `particle_${Math.round(Date.now() / 1000)}.webp`, 'image/webp');
172 | }
173 |
174 | public openSvgExportWindow() {
175 | const content = this.stageComponent.getParticleSvgString();
176 |
177 | const dataUrl = 'data:image/svg+xml,\n' + encodeURIComponent(content);
178 |
179 | const mimeType = 'text/plain';
180 | const fileName = `particle_${Math.round(Date.now() / 1000)}.svg`;
181 |
182 | // BOMは文字化け対策
183 | const bom = new Uint8Array([0xEF, 0xBB, 0xBF]);
184 | const blob = new Blob([bom, content], {type: mimeType});
185 |
186 | if (window.navigator.msSaveBlob) {
187 | // for IE
188 | window.navigator.msSaveBlob(blob, fileName);
189 | } else if (window.URL && window.URL.createObjectURL) {
190 | // for Firefox, Chrome, Safari
191 | const a = document.createElement('a');
192 | a.download = fileName;
193 | a.href = window.URL.createObjectURL(blob);
194 | document.body.appendChild(a);
195 | a.click();
196 | document.body.removeChild(a);
197 | } else {
198 | // for Safari
199 | window.open(dataUrl, '_blank');
200 | }
201 | }
202 |
203 | public handleExportParameterClick() {
204 | const exportData = Object.assign({}, this.drawingData);
205 | (exportData as any)['VERSION'] = VERSION;
206 |
207 | this.propetyModal.setIOButtonLink(JSON.stringify(exportData, null, ' '));
208 | this.propetyModal.openIOModal();
209 | }
210 | }
211 |
--------------------------------------------------------------------------------
/src/app/components/footer/footer.component.html:
--------------------------------------------------------------------------------
1 |
50 |
--------------------------------------------------------------------------------
/src/app/components/footer/footer.component.scss:
--------------------------------------------------------------------------------
1 | $grid-breakpoints: (
2 | xs: 0,
3 | sm: 576px,
4 | md: 768px,
5 | lg: 992px,
6 | xl: 1200px
7 | ) !default;
8 | $nav-tabs-border-color: black; // ics-custom
9 |
10 | :host {
11 | border-top: 1px solid $nav-tabs-border-color;
12 | filter: grayscale(100%);
13 | transition: all 0.2s;
14 | &:hover {
15 | filter: grayscale(0%);
16 | }
17 |
18 |
19 |
20 | > a {
21 | display: block;
22 | //@include hover-focus-active {
23 | // background-color: transparent;
24 | //}
25 |
26 | &:last-of-type {
27 | margin-left: 20px;
28 | }
29 |
30 |
31 | @media (max-width: 420px) {
32 | &:last-of-type {
33 | display: none;
34 | }
35 | }
36 | }
37 |
38 | > *:nth-child(2) {
39 | margin-left: rem-calc(5);
40 | margin-right: auto;
41 | }
42 |
43 | }
44 |
45 | .scope {
46 | &__grid {
47 | display: grid;
48 | width: 100%;
49 |
50 | grid-template-columns: auto 1fr auto;
51 | grid-template-rows: 35px;
52 | grid-template-areas: "tools sns maker";
53 |
54 | @media (max-width: map-get($grid-breakpoints, "md")) {
55 | grid-template-columns: 1fr;
56 | grid-template-rows: 35px;
57 | grid-template-areas: "sns";
58 | }
59 |
60 | &-tools {
61 | grid-area: tools;
62 | display: flex;
63 | align-items: center;
64 | padding-left: 10px;
65 |
66 | @media (max-width: map-get($grid-breakpoints, "md")) {
67 | display: none;
68 | }
69 | }
70 | &-sns {
71 | grid-area: sns;
72 | display: flex;
73 | justify-content: flex-end;
74 | align-items: center;
75 |
76 | @media (max-width: map-get($grid-breakpoints, "md")) {
77 | justify-content: center;
78 | }
79 | }
80 | &-maker {
81 | grid-area: maker;
82 | display: flex;
83 | align-items: center;
84 | padding-left: 20px;
85 | padding-right: 10px;
86 |
87 | @media (max-width: map-get($grid-breakpoints, "md")) {
88 | display: none;
89 | }
90 | }
91 | }
92 |
93 | }
94 |
95 |
--------------------------------------------------------------------------------
/src/app/components/footer/footer.component.ts:
--------------------------------------------------------------------------------
1 | import { Component, OnInit } from '@angular/core';
2 |
3 | @Component({
4 | selector: 'app-footer',
5 | templateUrl: './footer.component.html',
6 | styleUrls: ['./footer.component.scss']
7 | })
8 | export class FooterComponent implements OnInit {
9 |
10 | constructor() { }
11 |
12 | ngOnInit() {
13 | }
14 |
15 | }
16 |
--------------------------------------------------------------------------------
/src/app/components/header-desktop/header-desktop.component.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
8 |
14 |
15 |
16 |
17 |
18 |
20 |
24 |
25 |
26 |
27 |
28 |
--------------------------------------------------------------------------------
/src/app/components/header-desktop/header-desktop.component.scss:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/src/app/components/header-desktop/header-desktop.component.scss
--------------------------------------------------------------------------------
/src/app/components/header-desktop/header-desktop.component.ts:
--------------------------------------------------------------------------------
1 | import {DrawingData} from 'particlejs';
2 | import {LocaleData} from '../../i18n/locale-data';
3 | import {LocaleEnData} from '../../i18n/locale-en';
4 | import {LocaleJaData} from '../../i18n/locale-ja';
5 | import {LocaleManager} from '../../i18n/locale-manager';
6 | import {PlatformData} from '../../data/platform-data';
7 | import {Component, EventEmitter, Input, Output} from '@angular/core';
8 |
9 | @Component({
10 | selector: 'app-header-desktop',
11 | templateUrl: './header-desktop.component.html',
12 | styleUrls : ['header-desktop.component.scss'],
13 | })
14 |
15 | export class HeaderDesktopComponent {
16 | @Output() public exportSvgEvent = new EventEmitter();
17 | @Output() public exportPngEvent = new EventEmitter();
18 | @Output() public exportJpgEvent = new EventEmitter();
19 | @Output() public exportWebpEvent = new EventEmitter();
20 | @Output() public exportParameterEvent = new EventEmitter();
21 | @Output() public importParameterEvent = new EventEmitter();
22 |
23 | @Input() public drawingData!: DrawingData;
24 | @Input() public platformData!: PlatformData;
25 |
26 | public lastSelectFile: any;
27 |
28 | constructor(public localeData: LocaleData) {
29 | }
30 |
31 | public exportParameter(): void {
32 | this.exportParameterEvent.emit(null);
33 | }
34 |
35 | public exportSvg(): void {
36 | this.exportSvgEvent.emit(null);
37 | }
38 |
39 | public exportPng(): void {
40 | this.exportPngEvent.emit(null);
41 | }
42 |
43 | public exportJpg(): void {
44 | this.exportJpgEvent.emit(null);
45 | }
46 |
47 | public exportWebp(): void {
48 | this.exportWebpEvent.emit(null);
49 | }
50 |
51 | public selectParameterFile(obj: any): void {
52 | this.lastSelectFile = obj.target.files[0];
53 |
54 | this.importParameterEvent.emit(null);
55 | }
56 |
57 | public selectEn(): void {
58 | new LocaleManager().changeLocale(this.localeData, new LocaleEnData());
59 | }
60 |
61 | public selectJa(): void {
62 | new LocaleManager().changeLocale(this.localeData, new LocaleJaData());
63 | }
64 |
65 | }
66 |
--------------------------------------------------------------------------------
/src/app/components/header-mobile/header-mobile.component.html:
--------------------------------------------------------------------------------
1 |
2 | -
3 |
8 |
9 | -
10 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/src/app/components/header-mobile/header-mobile.component.scss:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/src/app/components/header-mobile/header-mobile.component.scss
--------------------------------------------------------------------------------
/src/app/components/header-mobile/header-mobile.component.ts:
--------------------------------------------------------------------------------
1 | import {Component, ElementRef, EventEmitter, Input, Output} from '@angular/core';
2 | import {DrawingData} from 'particlejs';
3 |
4 | @Component({
5 | selector : 'app-header-mobile',
6 | templateUrl: './header-mobile.component.html',
7 | styleUrls : ['header-mobile.component.scss'],
8 | })
9 | export class HeaderMobileComponent {
10 | @Output() exportPngEvent = new EventEmitter();
11 |
12 | @Input() drawingData!: DrawingData;
13 | private element: ElementRef;
14 |
15 | exportPng() {
16 | this.exportPngEvent.emit(null);
17 | }
18 |
19 | constructor(element: ElementRef) {
20 | this.element = element;
21 | }
22 | }
23 |
--------------------------------------------------------------------------------
/src/app/components/input-range/input-range.component.html:
--------------------------------------------------------------------------------
1 |
2 |
17 |
--------------------------------------------------------------------------------
/src/app/components/input-range/input-range.component.ts:
--------------------------------------------------------------------------------
1 | import {Component, Input} from '@angular/core';
2 | import {DrawingData} from 'particlejs';
3 | @Component({
4 | selector : 'app-input-range',
5 | styles : [`
6 | input[type=range] {
7 | display: block;
8 | width: 100%;
9 | }
10 | .row {
11 | padding-left: 0;
12 | padding-right: 0;
13 | justify-content: space-between;
14 | }
15 | [class*="col"] {
16 | padding-right: 0;
17 | padding-left: 0;
18 | }
19 | `],
20 | templateUrl: './input-range.component.html'
21 | })
22 | /**
23 | * Input タグ (range type)のコンポーネントです。
24 | * @author ICS-Ikeda
25 | * @since 2016-01-20
26 | */
27 | export class InputRangeComponent {
28 | @Input() public drawingData!: DrawingData;
29 |
30 | /** 対象のプロパティー名を指定します。 */
31 | @Input() public targetProperty!: string;
32 |
33 | /** ラベルの名称を指定します。 */
34 | @Input() public label!: string;
35 |
36 | /** 最小値を指定します。 */
37 | @Input() public min!: number;
38 |
39 | /** 最大値を指定します。 */
40 | @Input() public max!: number;
41 |
42 | /** ラベル間の間隔を示す数値を指定します。 */
43 | @Input() public step!: number;
44 |
45 | constructor() {
46 | }
47 |
48 | public handleChange(event: any): void {
49 | // なぜか string になっている可能性がある
50 | const tmp: any = this.drawingData;
51 | const value: any = tmp[this.targetProperty];
52 |
53 | // そのため、明示的な型変換を行う
54 | tmp[this.targetProperty] = Number(value);
55 | }
56 | }
57 |
--------------------------------------------------------------------------------
/src/app/components/modal-export-json/modal-export-json.component.html:
--------------------------------------------------------------------------------
1 |
29 |
--------------------------------------------------------------------------------
/src/app/components/modal-export-json/modal-export-json.component.scss:
--------------------------------------------------------------------------------
1 | textarea {
2 | height: 300px;
3 | margin-bottom: 1rem;
4 |
5 | color: #000;
6 | background: #bdbdbd;
7 | font-family: SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
8 | }
9 |
--------------------------------------------------------------------------------
/src/app/components/modal-export-json/modal-export-json.component.ts:
--------------------------------------------------------------------------------
1 | import {Component, ElementRef, Input, ViewChild} from '@angular/core';
2 | import * as jQuery from 'jquery';
3 | import {DrawingData} from 'particlejs';
4 | import {LocaleData} from '../../i18n/locale-data';
5 |
6 | @Component({
7 | selector : 'app-property-io-box',
8 | templateUrl: './modal-export-json.component.html',
9 | styleUrls : ['./modal-export-json.component.scss'],
10 | })
11 |
12 | export class ModalExportJsonComponent {
13 |
14 | @ViewChild('modal', { static: true }) modal: any;
15 | @ViewChild('outputLink', { static: true }) outputLink: any;
16 | @ViewChild('jsonValue', { static: true }) jsonValue: any;
17 |
18 | @Input() drawingData!: DrawingData;
19 |
20 | element: ElementRef;
21 |
22 | constructor(element: ElementRef, public localeData: LocaleData) {
23 | this.element = element;
24 | }
25 |
26 | public setIOButtonLink(json: string) {
27 | const link = (this.outputLink.nativeElement);
28 |
29 | link.download = 'parameter.json';
30 |
31 | if (navigator.userAgent.indexOf('Windows') > -1) {
32 | json = json.replace(/\n/g, '\r\n').replace(/\r\r/g, '\r');
33 | }
34 |
35 | const blob = new Blob([json], {type: 'text/plain'});
36 |
37 | link.href = window.URL.createObjectURL(blob);
38 |
39 | const textarea: HTMLTextAreaElement = this.jsonValue.nativeElement;
40 |
41 | // テキストエリアに値をセットする
42 | textarea.value = (json);
43 | }
44 |
45 | public openIOModal() {
46 | // 強引に連携
47 | (jQuery(this.modal.nativeElement) as any).modal('show');
48 | }
49 | }
50 |
--------------------------------------------------------------------------------
/src/app/components/modal-template/modal-template.component.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
10 |
11 |
12 |
15 |
16 | {{template.name}}
17 |
18 |
19 |
20 |
23 |
24 |
25 |
26 |
27 |
28 |
--------------------------------------------------------------------------------
/src/app/components/modal-template/modal-template.component.scss:
--------------------------------------------------------------------------------
1 | .scope-list {
2 | display: flex;
3 | flex-wrap: wrap;
4 | width: 100%;
5 | justify-content: space-between;
6 | }
7 |
8 | figure {
9 | width: 33%;
10 | box-sizing: border-box;
11 | margin-bottom: rem-calc(8.5);
12 | padding-left: 5px;
13 | padding-right: 5px;
14 |
15 | img {
16 | width: 100%;
17 | height: auto;
18 | cursor: pointer;
19 | border: 1px solid #555;
20 |
21 | }
22 |
23 | &:hover {
24 | img {
25 | border-color: #999;
26 | }
27 | }
28 |
29 | figcaption {
30 | font-size: 1.0rem;
31 | color: #999;
32 | text-align: center;
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/src/app/components/modal-template/modal-template.component.ts:
--------------------------------------------------------------------------------
1 | import {Component, Input, OnInit} from '@angular/core';
2 | import {DrawingData} from 'particlejs';
3 | import {ParticleParameter} from '../../assets/particle-parameter';
4 | import {LocaleData} from '../../i18n/locale-data';
5 |
6 | @Component({
7 | selector : 'app-modal-template',
8 | templateUrl: './modal-template.component.html',
9 | styleUrls : ['./modal-template.component.scss'],
10 | })
11 |
12 | export class ModalTemplateComponent implements OnInit {
13 | @Input() drawingData!: DrawingData;
14 | @Input() templateList: any[];
15 | public template!: ParticleParameter;
16 |
17 | constructor(public localeData: LocaleData) {
18 | const template = new ParticleParameter();
19 | this.templateList = template.list;
20 | }
21 |
22 | ngOnInit() {
23 | // テンプレートを適用
24 | this.drawingData.importData(this.templateList[0].property);
25 | }
26 |
27 | public selectTemplate(value: DrawingData) {
28 | this.drawingData.importData(value);
29 | }
30 | }
31 |
--------------------------------------------------------------------------------
/src/app/components/properties/property-canvas/property-canvas.component.html:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 |
12 |
13 |
14 |
20 |
21 |
22 |
23 |
26 |
27 |
31 | {{drawingData.bgColor}}
32 |
33 |
34 |
--------------------------------------------------------------------------------
/src/app/components/properties/property-canvas/property-canvas.component.scss:
--------------------------------------------------------------------------------
1 | input[type="color"] {
2 | margin-right: 10px;
3 | }
4 |
--------------------------------------------------------------------------------
/src/app/components/properties/property-canvas/property-canvas.component.ts:
--------------------------------------------------------------------------------
1 | import {Component, Input} from '@angular/core';
2 | import {DrawingData} from 'particlejs';
3 | import {LocaleData} from '../../../i18n/locale-data';
4 |
5 | @Component({
6 | selector : 'app-canvas-property-panel',
7 | templateUrl: './property-canvas.component.html',
8 | styleUrls : ['property-canvas.component.scss'],
9 | })
10 |
11 | export class PropertyCanvasPanelComponent {
12 | @Input() public drawingData!: DrawingData;
13 |
14 | constructor(public localeData: LocaleData) {
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/src/app/components/properties/property-color/property-color-unit.component.html:
--------------------------------------------------------------------------------
1 |
7 |
8 |
9 |
12 |
13 |
19 |
20 |
21 |
22 |
28 |
29 |
32 |
33 |
39 |
40 |
41 |
47 |
48 |
51 |
52 |
53 |
59 |
60 |
--------------------------------------------------------------------------------
/src/app/components/properties/property-color/property-color-unit.component.scss:
--------------------------------------------------------------------------------
1 | [class*="gradation"] {
2 | width: 100%;
3 | flex-basis: 80%;
4 | height: 1px;
5 | }
6 |
7 | .gradation-box {
8 | width: 75%;
9 |
10 | &-hue {
11 | background-image: linear-gradient(to right, red 0%, #ccff00 20%, #00ff66 40%, #0066ff 60%, #cc00ff 80%, red 100%);
12 | }
13 |
14 | &-saturation {
15 | background-image: linear-gradient(to right, gray 0%, red 100%);
16 | }
17 |
18 | &-luminance {
19 | background-image: linear-gradient(to right, black 0%, white 100%);
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/src/app/components/properties/property-color/property-color-unit.component.ts:
--------------------------------------------------------------------------------
1 | import {Component, Input} from '@angular/core';
2 | import {ColorData} from 'particlejs';
3 | import {LocaleData} from '../../../i18n/locale-data';
4 |
5 | @Component({
6 | selector : 'app-color-unit-property-panel',
7 | templateUrl: './property-color-unit.component.html',
8 | styleUrls : ['property-color-unit.component.scss'],
9 | })
10 | export class PropertyColorUnitComponent {
11 | @Input() public colorData!: ColorData;
12 |
13 | constructor(public localeData: LocaleData) {
14 | }
15 |
16 | }
17 |
--------------------------------------------------------------------------------
/src/app/components/properties/property-color/property-color.component.html:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 |
7 |
13 |
14 |
20 |
21 |
22 |
23 |
26 |
27 |
33 |
34 |
40 |
41 |
42 |
43 |
44 |
45 |
48 |
49 |
52 |
53 |
54 |
55 |
58 |
59 |
63 |
64 |
65 |
--------------------------------------------------------------------------------
/src/app/components/properties/property-color/property-color.component.scss:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/src/app/components/properties/property-color/property-color.component.scss
--------------------------------------------------------------------------------
/src/app/components/properties/property-color/property-color.component.ts:
--------------------------------------------------------------------------------
1 | import {Component, Input} from '@angular/core';
2 | import {AlphaCurveType, DrawingData} from 'particlejs';
3 | import {LocaleData} from '../../../i18n/locale-data';
4 |
5 | interface TestObject {
6 | name: string;
7 | value: number;
8 | }
9 |
10 | @Component({
11 | selector : 'app-color-property-panel',
12 | templateUrl: './property-color.component.html',
13 | styleUrls : ['./property-color.component.scss'],
14 | })
15 |
16 | export class PropertyColorPanelComponent {
17 | @Input() public drawingData!: DrawingData;
18 | public objArray: TestObject[];
19 |
20 | constructor(public localeData: LocaleData) {
21 | this.objArray = [
22 | {name: 'Normal', value: AlphaCurveType.Normal},
23 | {name: 'Random', value: AlphaCurveType.Random},
24 | ];
25 | }
26 | }
27 |
--------------------------------------------------------------------------------
/src/app/components/properties/property-emitter/property-emitter.component.html:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 |
7 |
13 |
14 |
15 |
21 |
22 |
23 |
24 |
25 |
31 |
32 |
33 |
39 |
40 |
41 |
42 |
43 |
49 |
50 |
51 |
56 |
57 |
58 |
59 |
60 |
66 |
67 |
68 |
69 |
70 |
76 |
77 |
78 |
84 |
85 |
86 |
87 |
88 |
94 |
95 |
96 |
97 |
--------------------------------------------------------------------------------
/src/app/components/properties/property-emitter/property-emitter.component.ts:
--------------------------------------------------------------------------------
1 | import {DrawingData} from 'particlejs';
2 | import {LocaleData} from '../../../i18n/locale-data';
3 | import {Component, Input} from '@angular/core';
4 |
5 | @Component({
6 | selector : 'app-emitter-property-panel',
7 | templateUrl: './property-emitter.component.html'
8 | })
9 |
10 | export class PropertyEmitterPanelComponent {
11 | @Input() public drawingData!: DrawingData;
12 |
13 | constructor(public localeData: LocaleData) {
14 | }
15 | }
16 |
--------------------------------------------------------------------------------
/src/app/components/properties/property-particle/property-particle.component.html:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 |
7 |
13 |
14 |
15 |
21 |
22 |
23 |
24 |
30 |
31 |
32 |
38 |
39 |
40 |
41 |
42 |
48 |
49 |
50 |
56 |
57 |
58 |
59 |
--------------------------------------------------------------------------------
/src/app/components/properties/property-particle/property-particle.component.ts:
--------------------------------------------------------------------------------
1 | import {DrawingData} from 'particlejs';
2 | import {LocaleData} from '../../../i18n/locale-data';
3 | import {Component, Input} from '@angular/core';
4 |
5 | @Component({
6 | selector : 'app-particle-property-panel',
7 | templateUrl: './property-particle.component.html'
8 | })
9 |
10 | export class PropertyParticlePanelComponent {
11 | @Input() drawingData!: DrawingData;
12 | @Input() shapeIdList: any;
13 |
14 | constructor(public localeData: LocaleData) {
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/src/app/components/properties/property-shape/property-shape-itemrenderer.component.html:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/src/app/components/properties/property-shape/property-shape-itemrenderer.component.ts:
--------------------------------------------------------------------------------
1 | import {AfterViewInit, Component, Input, ViewChild} from '@angular/core';
2 | import {Assets} from 'particlejs';
3 |
4 | @Component({
5 | selector : 'app-shape-itemrenderer',
6 | templateUrl: './property-shape-itemrenderer.component.html',
7 | })
8 |
9 | /**
10 | * シェイプの選択パネル内のアイテムレンダラーです。
11 | */
12 | export class PropertyShapeItemRendererComponent implements AfterViewInit {
13 | @Input() private shapeId!: string;
14 |
15 | @ViewChild('myCanvas', { static: true }) myCanvas: any;
16 |
17 | constructor() {
18 | }
19 |
20 | ngAfterViewInit() {
21 | const canvas = this.myCanvas.nativeElement;
22 |
23 | const stage = new createjs.Stage(canvas);
24 |
25 | // Adobe Animate CCから書きだしたシェイプを使う
26 | const cls = (Assets as any)[this.shapeId];
27 |
28 | const shape = new cls();
29 | shape.x = 32;
30 | shape.y = 32;
31 | shape.scaleX = shape.scaleY = 0.5;
32 | // はい、レンダーする
33 | stage.addChild(shape);
34 |
35 | // おわり
36 | stage.update();
37 | }
38 | }
39 |
40 |
--------------------------------------------------------------------------------
/src/app/components/properties/property-shape/property-shape.component.html:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 |
7 |
8 |
-1"
11 | (click)="handleClick(shapeId)">
12 |
16 |
17 |
18 |
19 |
20 |
--------------------------------------------------------------------------------
/src/app/components/properties/property-shape/property-shape.component.scss:
--------------------------------------------------------------------------------
1 | .scope-list-item {
2 | cursor: pointer;
3 | display: block;
4 | width: 64px;
5 | height: 64px;
6 | box-sizing: border-box;
7 | line-height: 0;
8 | margin-bottom: 15px;
9 | margin-right: 15px;
10 | border: 1px solid rgba(0, 0, 0, 0.1);
11 | transition: all 0.15s;
12 |
13 | &:hover, &.selected {
14 | background: #222;
15 | border-color: #333;
16 | }
17 | }
18 |
--------------------------------------------------------------------------------
/src/app/components/properties/property-shape/property-shape.component.ts:
--------------------------------------------------------------------------------
1 | import {Component, Input} from '@angular/core';
2 | import {DrawingData, ShapeData} from 'particlejs';
3 | import {LocaleData} from '../../../i18n/locale-data';
4 |
5 | @Component({
6 | selector : 'app-shape-property-panel',
7 | templateUrl: './property-shape.component.html',
8 | styleUrls : ['property-shape.component.scss'],
9 | })
10 |
11 | /**
12 | * シェイプの選択パネルの制御クラスです。
13 | */
14 | export class PropertyShapePanelComponent {
15 | @Input() public drawingData!: DrawingData;
16 | @Input() public shapeIdList: string[] = new ShapeData().assetList;
17 |
18 | constructor(public localeData: LocaleData) {
19 | }
20 |
21 | public handleClick(shapeId: string) {
22 |
23 | const index = this.drawingData.shapeIdList.indexOf(shapeId);
24 | if (index === -1) { // 含まれていなければ
25 | // 追加
26 | this.drawingData.shapeIdList.push(shapeId);
27 | } else { // 含まれていたら
28 | // 2個以上のときのみ
29 | if (this.drawingData.shapeIdList.length >= 2) {
30 | // 削除
31 | this.drawingData.shapeIdList.splice(index, 1);
32 | }
33 | }
34 | }
35 |
36 | }
37 |
--------------------------------------------------------------------------------
/src/app/components/properties/property-template/property-template.component.html:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
13 |
17 | {{template.name}}
18 |
19 |
20 |
21 |
22 |
--------------------------------------------------------------------------------
/src/app/components/properties/property-template/property-template.component.scss:
--------------------------------------------------------------------------------
1 | .scope-list {
2 | display: flex;
3 | flex-wrap: wrap;
4 | width: 100%;
5 | justify-content: space-between;
6 | }
7 |
8 | figure {
9 | width: 33%;
10 | box-sizing: border-box;
11 | margin-bottom: rem-calc(8.5);
12 | padding-left: 5px;
13 | padding-right: 5px;
14 | cursor: pointer;
15 | user-select: none;
16 |
17 | img {
18 | width: 100%;
19 | height: auto;
20 | border: 1px solid #555;
21 | pointer-events: none;
22 | transition: all 0.15s;
23 | }
24 |
25 | &:hover {
26 | img {
27 | border-color: #999;
28 | }
29 | }
30 |
31 | figcaption {
32 | font-size: 1.0rem;
33 | color: #999;
34 | text-align: center;
35 | }
36 | }
37 |
--------------------------------------------------------------------------------
/src/app/components/properties/property-template/property-template.component.ts:
--------------------------------------------------------------------------------
1 | import {Component, Input, OnInit} from '@angular/core';
2 | import {DrawingData} from 'particlejs';
3 | import {ParticleParameter} from '../../../assets/particle-parameter';
4 | import {LocaleData} from '../../../i18n/locale-data';
5 |
6 | @Component({
7 | selector : 'app-particle-template-property-panel',
8 | styleUrls : ['./property-template.component.scss'],
9 | templateUrl: './property-template.component.html',
10 | })
11 |
12 |
13 | export class PropertyTemplatePanelComponent implements OnInit {
14 | @Input() drawingData!: DrawingData;
15 | @Input() templateList: any[];
16 | public public!: ParticleParameter;
17 |
18 | constructor(public localeData: LocaleData) {
19 | const template = new ParticleParameter();
20 |
21 | this.templateList = template.list;
22 | }
23 |
24 | ngOnInit() {
25 | // テンプレートを適用
26 | this.drawingData.importData(this.templateList[0].property);
27 | }
28 |
29 | public selectTemplate(value: DrawingData) {
30 | this.drawingData.importData(value);
31 | }
32 | }
33 |
--------------------------------------------------------------------------------
/src/app/components/properties/property.component.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
18 |
19 |
20 |
24 |
25 |
26 |
30 |
31 |
32 |
36 |
37 |
38 |
42 |
43 |
44 |
48 |
49 |
50 |
51 |
--------------------------------------------------------------------------------
/src/app/components/properties/property.component.scss:
--------------------------------------------------------------------------------
1 | $gray-900: #323232 !default;
2 |
3 | ::ng-deep .pd-property {
4 | flex: 285px;
5 | height: 100%;
6 | overflow: hidden;
7 |
8 | &__inner {
9 | height: 100%;
10 | background-color: $gray-900;
11 | }
12 |
13 | .nav-tabs {
14 | a {
15 | padding: rem-calc(2) rem-calc(15);
16 | font-size: rem-calc(16);
17 | }
18 | .nav-item {
19 | height: 35px;
20 | }
21 | }
22 |
23 | &__ul {
24 | background: #222222;
25 | }
26 | &__nav-item{
27 | padding: 0 1rem;
28 | line-height: 35px;
29 | background: #222222;
30 | }
31 |
32 | .tab-content {
33 | height: calc(100vh - 125px);
34 | overflow: auto;
35 | }
36 |
37 | .pd-section {
38 | height: 100%;
39 | overflow-y: auto;
40 | border: none;
41 |
42 | &__header {
43 | padding-top: 10px;
44 | padding-bottom: 10px;
45 | border: none;
46 |
47 | + hr {
48 | margin-top: 0;
49 | }
50 | h3 {
51 | text-align: center;
52 | }
53 | }
54 |
55 | &__block {
56 |
57 | padding-left: 10px;
58 | padding-right: 10px;
59 |
60 | &__list {
61 | display: flex;
62 | flex-wrap: wrap;
63 | }
64 | }
65 |
66 | hr {
67 | margin-top: rem-calc(12);
68 | margin-bottom: rem-calc(12);
69 | }
70 | }
71 |
72 | // IE11 & Edge のスクロールバー対策
73 | .tab-pane {
74 | height: 100%;
75 | }
76 | }
77 |
78 |
--------------------------------------------------------------------------------
/src/app/components/properties/property.component.ts:
--------------------------------------------------------------------------------
1 | import {Component, Input} from '@angular/core';
2 | import {DrawingData} from 'particlejs';
3 | import {LocaleData} from '../../i18n/locale-data';
4 |
5 | @Component({
6 | selector : 'app-property-panel',
7 | templateUrl: './property.component.html',
8 | styleUrls : ['property.component.scss'],
9 | })
10 | export class PropertyPanelComponent {
11 | @Input() public drawingData!: DrawingData;
12 |
13 | constructor(public localeData: LocaleData) {
14 | }
15 | }
16 |
--------------------------------------------------------------------------------
/src/app/components/stage/stage.component.ts:
--------------------------------------------------------------------------------
1 | import {AfterViewInit, Component, Input, ViewChild} from '@angular/core';
2 | import {DrawingData} from 'particlejs';
3 | import {ParticleCanvas} from '../../particle/particle-canvas';
4 |
5 | @Component({
6 | selector: 'app-stage',
7 | template: `
8 |
20 | `
21 | })
22 |
23 | export class StageComponent implements AfterViewInit {
24 |
25 | @ViewChild('myCanvas', { static: true }) myCanvas: any;
26 |
27 | @Input() drawingData!: DrawingData;
28 | private particleCanvas!: ParticleCanvas;
29 |
30 | constructor() {
31 |
32 | }
33 |
34 | private onResumeClick() {
35 | this.particleCanvas.resume();
36 | }
37 |
38 | private onPauseClick() {
39 | this.particleCanvas.pause();
40 | }
41 |
42 | public exportSvg(): Promise {
43 | return this.particleCanvas.runExport();
44 | }
45 |
46 | public toDataURL(type: string, params: string): string {
47 | return this.particleCanvas.toDataURL(type, params);
48 | }
49 |
50 | public runExportSP(): Promise {
51 | return this.particleCanvas.runExportSP();
52 | }
53 |
54 | public runCamera(): Promise {
55 | return this.particleCanvas.runCamera();
56 | }
57 |
58 | ngAfterViewInit() {
59 | const canvas = this.myCanvas.nativeElement;
60 | this.particleCanvas = new ParticleCanvas(canvas, this.drawingData);
61 |
62 | createjs.Ticker.framerate = 60;
63 | createjs.Ticker.timingMode = createjs.Ticker.RAF;
64 | createjs.Ticker.on('tick', this.handleTick, this);
65 |
66 | canvas.addEventListener('contextmenu', (event: Event) => {
67 | this.handleContextMenu(event);
68 | });
69 | }
70 |
71 | public getParticleSvgString(): string {
72 | return this.particleCanvas.getSvgString();
73 | }
74 |
75 | private handleTick() {
76 | this.particleCanvas.update(this.drawingData);
77 | }
78 |
79 | private handleContextMenu(event: Event) {
80 | event.preventDefault();
81 | }
82 | }
83 |
--------------------------------------------------------------------------------
/src/app/data/platform-data.ts:
--------------------------------------------------------------------------------
1 | import {PlatformType} from '../enum/platform-type';
2 |
3 | export class PlatformData {
4 |
5 | public platformType: PlatformType;
6 |
7 | constructor(platformType: PlatformType) {
8 | this.platformType = platformType;
9 | }
10 |
11 | public isDesktop(): boolean {
12 | return this.platformType === PlatformType.Desktop;
13 | }
14 |
15 | public enableOutputParameter(): boolean {
16 | return true;
17 | }
18 |
19 | public enableInputParameter(): boolean {
20 | return this.platformType === PlatformType.Desktop;
21 | }
22 | }
23 |
--------------------------------------------------------------------------------
/src/app/enum/canvas-margin.ts:
--------------------------------------------------------------------------------
1 | export enum CanvasMargin {
2 | TOP_DESKTOP = 85,
3 | RIGHT_DESKTOP = 350,
4 | TOP_MOBILE = 85,
5 | RIGHT_MOBILE = 7
6 | }
7 |
--------------------------------------------------------------------------------
/src/app/enum/platform-type.ts:
--------------------------------------------------------------------------------
1 | export enum PlatformType {
2 | Browser = 0,
3 | Desktop = 1,
4 | Mobile = 2
5 | }
6 |
--------------------------------------------------------------------------------
/src/app/enum/view-port.ts:
--------------------------------------------------------------------------------
1 | export enum Viewport {
2 | sm = 768
3 | }
4 |
--------------------------------------------------------------------------------
/src/app/i18n/locale-data.ts:
--------------------------------------------------------------------------------
1 | import {Injectable} from '@angular/core';
2 |
3 | @Injectable()
4 | export class LocaleData {
5 | MA_head = '';
6 | MA_sentence = '';
7 |
8 | H_about = '';
9 | H_exportImage = '';
10 | H_exportParam = '';
11 | H_language = '';
12 |
13 | preview_head = '';
14 | settings_head = '';
15 |
16 | ST_head = '';
17 |
18 | SE_head = '';
19 | SE_startXVariance = '';
20 | SE_startYVariance = '';
21 | SE_initialSpeed = '';
22 | SE_initialSpeedVariance = '';
23 | SE_initialDirection = '';
24 | SE_initialDirectionVariance = '';
25 | SE_friction = '';
26 | SE_accelerationSpeed = '';
27 | SE_accelerationDirection = '';
28 | SE_emitFrequency = '';
29 |
30 | SP_head = '';
31 | SP_startScale = '';
32 | SP_startScaleVariance = '';
33 | SP_endScale = '';
34 | SP_endScaleVariance = '';
35 | SP_lifeSpan = '';
36 | SP_lifeSpanVariance = '';
37 |
38 | SC_head_start = '';
39 | SC_hue = '';
40 | SC_hueVariance = '';
41 | SC_saturation = '';
42 | SC_saturationVariance = '';
43 | SC_luminance = '';
44 | SC_luminanceVariance = '';
45 | SC_startAlpha = '';
46 | SC_startAlphaVariance = '';
47 |
48 | SC_head_end = '';
49 | SC_endAlpha = '';
50 | SC_endAlphaVariance = '';
51 |
52 | SC_head_alphaCurve = '';
53 | SC_head_blendMode = '';
54 |
55 | SS_head = '';
56 |
57 | SF_head = '';
58 | SF_stageW = '';
59 | SF_stageH = '';
60 | SF_bgColor = '';
61 |
62 |
63 | MC_head = '';
64 | MC_button = '';
65 | }
66 |
--------------------------------------------------------------------------------
/src/app/i18n/locale-en.ts:
--------------------------------------------------------------------------------
1 | import {LocaleData} from './locale-data';
2 |
3 | export class LocaleEnData extends LocaleData {
4 |
5 | MA_head = 'What is Particle Develop';
6 | MA_sentence = `Particle Develop is the design tool available to create
7 | particle graphics such as snow and fire.
8 | The graphic of particles are vector,
9 | you can save as SVG file, and edit with Adobe Illustrator.`;
10 |
11 | H_about = 'About';
12 | H_exportImage = 'Export as File';
13 | H_exportParam = 'Save Config Data';
14 | H_language = 'Language';
15 |
16 | preview_head = 'Preview';
17 | settings_head = 'Settings';
18 |
19 | ST_head = 'Template Settings';
20 |
21 | SE_head = 'Emitter Settings';
22 | SE_startXVariance = 'Source Position Variance X (px)';
23 | SE_startYVariance = 'Source Position Variance Y (px)';
24 | SE_initialSpeed = 'Speed (px/frame)';
25 | SE_initialSpeedVariance = 'Speed Variance (px/frame)';
26 | SE_initialDirection = 'Emit Angle (degree)';
27 | SE_initialDirectionVariance = 'Emit Angle Variance (degree)';
28 | SE_friction = 'Friction';
29 | SE_accelerationSpeed = 'Gravity';
30 | SE_accelerationDirection = 'Gravity Angle (degree)';
31 | SE_emitFrequency = 'Emit Frequency (num/sec)';
32 |
33 | SP_head = 'Particle Settings';
34 | SP_startScale = 'Start Size';
35 | SP_startScaleVariance = 'Start Size Variance';
36 | SP_endScale = 'End Size';
37 | SP_endScaleVariance = 'End Size Variance';
38 | SP_lifeSpan = 'Lifespan (frame)';
39 | SP_lifeSpanVariance = 'Lifespan Variance (frame)';
40 |
41 | SC_head_start = 'Start Color';
42 | SC_hue = 'Hue (degree)';
43 | SC_hueVariance = 'Hue Variance (degree)';
44 | SC_saturation = 'Saturation (%)';
45 | SC_saturationVariance = 'Saturation Variance (%)';
46 | SC_luminance = 'Luminance (%)';
47 | SC_luminanceVariance = 'Luminance Variance (%)';
48 | SC_startAlpha = 'Alpha';
49 | SC_startAlphaVariance = 'Alpha Variance';
50 |
51 | SC_head_end = 'End Color';
52 | SC_endAlpha = 'Alpha';
53 | SC_endAlphaVariance = 'Alpha Variance';
54 |
55 | SC_head_alphaCurve = 'Alpha Motion Type';
56 | SC_head_blendMode = 'Blend Mode';
57 |
58 | SS_head = 'Shape Settings';
59 |
60 | SF_head = 'Stage Settings';
61 | SF_stageW = 'Width (px)';
62 | SF_stageH = 'Height (px)';
63 | SF_bgColor = 'Background Color';
64 |
65 |
66 | MC_head = 'Save Config Data';
67 | MC_button = 'Save as File (.json)';
68 | }
69 |
--------------------------------------------------------------------------------
/src/app/i18n/locale-ja.ts:
--------------------------------------------------------------------------------
1 | import {LocaleData} from './locale-data';
2 |
3 | export class LocaleJaData extends LocaleData {
4 |
5 | MA_head = 'このサイトについて';
6 | MA_sentence = `
7 | Particle Developは雪や炎などのパーティクル表現が作れるHTML5製のデザインツールです。
8 | 炎や雪の表現はベクターグラフィックとなっているので、保存したSVGファイルはAdobe Illustratorで配置したり、再編集できます。
9 | ベクターのパーティクルデザインツールということが、他のツールにないParticle Developの特徴です。
10 | ※このツールで作成した画像ファイルやJSONファイルは個人・商用利用ともに無償でお使いいただけます。著作権はそれらを制作した方に帰属します。
11 | `;
12 |
13 | H_about = 'このサイトについて';
14 | H_exportImage = 'イメージの書き出し';
15 | H_exportParam = 'パラメーター保存';
16 | H_language = 'Language';
17 |
18 | preview_head = 'プレビュー';
19 | settings_head = '設定';
20 |
21 | ST_head = 'テンプレート設定';
22 |
23 | SE_head = 'エミッター設定';
24 | SE_startXVariance = '発生位置 - X座標のばらつき (px)';
25 | SE_startYVariance = '発生位置 - Y座標のばらつき (px)';
26 | SE_initialSpeed = '初期速度 (px)';
27 | SE_initialSpeedVariance = '初期速度のばらつき';
28 | SE_initialDirection = '初期速度 - 方向 (度)';
29 | SE_initialDirectionVariance = '初期速度 - 方向のばらつき (度)';
30 | SE_friction = '摩擦';
31 | SE_accelerationSpeed = '重力';
32 | SE_accelerationDirection = '重力方向 (度)';
33 | SE_emitFrequency = '1秒あたりの発生数 (個/秒)';
34 |
35 | SP_head = 'パーティクル設定';
36 | SP_startScale = '開始時のスケール';
37 | SP_startScaleVariance = '開始時のスケールのばらつき';
38 | SP_endScale = '終了時のスケール';
39 | SP_endScaleVariance = '終了時のスケールのばらつき';
40 | SP_lifeSpan = 'ライフ (フレーム数)';
41 | SP_lifeSpanVariance = 'ライフのばらつき (フレーム数)';
42 |
43 | SC_head_start = '開始色';
44 | SC_hue = '色相 (度)';
45 | SC_hueVariance = '色相のばらつき (度)';
46 | SC_saturation = '彩度 (%)';
47 | SC_saturationVariance = '彩度のばらつき (%)';
48 | SC_luminance = '明度 (%)';
49 | SC_luminanceVariance = '明度のばらつき (%)';
50 | SC_startAlpha = '開始時の透明度';
51 | SC_startAlphaVariance = '開始時の透明度のばらつき';
52 |
53 | SC_head_end = '終了色';
54 | SC_endAlpha = '終了時の透明度';
55 | SC_endAlphaVariance = '終了時の透明度のばらつき';
56 |
57 | SC_head_alphaCurve = '透明度の変化';
58 | SC_head_blendMode = 'ブレンドモード';
59 |
60 | SS_head = '形状設定';
61 |
62 | SF_head = 'ステージ設定';
63 | SF_stageW = 'ステージの幅 (px)';
64 | SF_stageH = 'ステージの高さ (px)';
65 | SF_bgColor = '背景色';
66 |
67 | MC_head = 'パラメーター保存';
68 | MC_button = 'ファイルとして保存 (.json)';
69 | }
70 |
--------------------------------------------------------------------------------
/src/app/i18n/locale-manager.ts:
--------------------------------------------------------------------------------
1 | import {LocaleData} from './locale-data';
2 | import {LocaleJaData} from './locale-ja';
3 | import {LocaleEnData} from './locale-en';
4 |
5 | export class LocaleManager {
6 |
7 | public applyClientLocale(localeData: LocaleData): void {
8 | const locale = this.checkLocale();
9 | let lData: LocaleData;
10 |
11 | switch (locale) {
12 | case 'ja':
13 | lData = new LocaleJaData();
14 | break;
15 | case 'en':
16 | default:
17 | lData = new LocaleEnData();
18 | break;
19 | }
20 | this.changeLocale(localeData, lData);
21 | }
22 |
23 | public checkLocale(): string | undefined {
24 | const ua = window.navigator.userAgent.toLowerCase();
25 | const navi = navigator;
26 | try {
27 | // chrome
28 | if (ua.indexOf('chrome') !== -1) {
29 | return ( navi.languages[0] || navi.browserLanguage || navi.language || navi.userLanguage).substr(0, 2);
30 | } else {
31 | // それ以外
32 | return ( navi.browserLanguage || navi.language || navi.userLanguage).substr(0, 2);
33 | }
34 | } catch (e) {
35 | return undefined;
36 | }
37 | }
38 |
39 |
40 | public changeLocale(master: LocaleData, selectedLocale: LocaleData): void {
41 | for (const key in selectedLocale) {
42 | if (Reflect.has(selectedLocale, key) === true) {
43 | const val = (selectedLocale as any)[key];
44 | Reflect.set(master, key, val);
45 | }
46 | }
47 | }
48 | }
49 |
50 |
--------------------------------------------------------------------------------
/src/app/particle/particle-canvas.ts:
--------------------------------------------------------------------------------
1 | import {DrawingData, ParticleSystem} from 'particlejs';
2 | import {Viewport} from '../enum/view-port';
3 | import {CanvasMargin} from '../enum/canvas-margin';
4 | import {ParticleExporter} from './particle-exporter';
5 | import {PartcicleImageImporter} from './particle-image-importer';
6 | import {ParticleCaptureImageLayer} from './particle-capture-image-layer';
7 | import {Ruler} from './particle-ruler';
8 |
9 | /**
10 | * パーティクル表示エリアの制御クラスです。
11 | */
12 | export class ParticleCanvas {
13 |
14 | private _data: DrawingData;
15 |
16 | /** 背景の表示オブジェクトです。 */
17 | private _background: createjs.Shape;
18 |
19 | private _captureImageLayer: ParticleCaptureImageLayer;
20 |
21 | /** canvas 要素です。 */
22 | private _canvas: HTMLCanvasElement;
23 |
24 | /** CreateJS の Stage インスタンスです。 */
25 | private _stage: createjs.Stage;
26 |
27 | private _canvasContainer: createjs.Container;
28 | private _wrapperForCapure: createjs.Container;
29 | private _backgroundColorCommand: any;
30 | private _backgroundSize: any;
31 |
32 | /** パーティクルエミッターのインスタンスです。 */
33 | private _particleSystem: ParticleSystem;
34 |
35 | /** パーティクルの設定情報生成のインスタンスです。 */
36 | private _particleExporter: ParticleExporter;
37 |
38 | /** パーティクルの画像生成のインスタンスです。 */
39 | private _partcileImageImporter: PartcicleImageImporter;
40 |
41 | private _ruler: Ruler;
42 |
43 | /** 座布団 */
44 | private _outerZabuton: createjs.Shape = new createjs.Shape();
45 |
46 | constructor(canvas: any, data: DrawingData) {
47 |
48 | this._data = data;
49 | this._canvas = canvas;
50 |
51 | this._canvas.width = data.width;
52 | this._canvas.height = data.height;
53 |
54 | this._stage = new createjs.Stage(this._canvas);
55 |
56 | // ステージをモバイル対応させる
57 | if (createjs.Touch.isSupported() === true) {
58 | createjs.Touch.enable(this._stage);
59 | }
60 |
61 | this._wrapperForCapure = new createjs.Container();
62 | this._stage.addChild(this._wrapperForCapure);
63 |
64 | this._canvasContainer = new createjs.Container();
65 | this._wrapperForCapure.addChild(this._canvasContainer);
66 |
67 |
68 | // キャンバスより後ろ
69 | this._background = new createjs.Shape();
70 | this._backgroundColorCommand = this._background.graphics.beginFill('gray').command;
71 | this._backgroundSize = this._background.graphics.drawRect(0, 0, data.width, data.height).command;
72 |
73 |
74 | this._backgroundColorCommand.style = data.bgColor;
75 | this._backgroundSize.w = data.width;
76 | this._backgroundSize.h = data.height;
77 |
78 | this._canvasContainer.addChild(this._background);
79 |
80 | this._captureImageLayer = new ParticleCaptureImageLayer();
81 | this._canvasContainer.addChild(this._captureImageLayer);
82 |
83 | this._particleSystem = new ParticleSystem();
84 | this._canvasContainer.addChild(this._particleSystem.container);
85 |
86 | this._particleExporter = new ParticleExporter(this._particleSystem.container);
87 |
88 | this._partcileImageImporter = new PartcicleImageImporter();
89 |
90 | // 座布団
91 | this._stage.addChild(this._outerZabuton);
92 |
93 | // ルーラーは最前面
94 | this._ruler = new Ruler(this._data);
95 | this._ruler.setSize(data.width, data.height);
96 | this._stage.addChild(this._ruler.container);
97 |
98 | // リサイズイベント
99 | this.resizeHandler();
100 | window.addEventListener('resize', () => this.resizeHandler());
101 | }
102 |
103 | public pause(): void {
104 | this._particleSystem.pause();
105 | }
106 |
107 | public resume(): void {
108 | this._particleSystem.resume();
109 | }
110 |
111 | public getSvgString(): string {
112 | return this._particleExporter.getSvgString();
113 | }
114 |
115 | public runExport(): Promise {
116 | return this._particleExporter.runExport(this._data.width, this._data.height);
117 | }
118 |
119 | public runExportSP(): Promise {
120 | return this._particleExporter.runExportSP(this._canvas);
121 | }
122 |
123 | public runCamera(): Promise {
124 | const canvasWidth: number = (this._stage.canvas).width;
125 | const canvasHeight: number = (this._stage.canvas).height;
126 | return this._partcileImageImporter.getCapture(canvasWidth, canvasHeight).then(
127 | (imageData) => this.insertCaptureToStage(imageData)
128 | );
129 | }
130 |
131 | /**
132 | * Stageにキャプチャー画像を挿入します。
133 | */
134 | private insertCaptureToStage(imageData: string): void {
135 | this._captureImageLayer.addImageFromImageData(imageData);
136 | this._stage.update();
137 | }
138 |
139 | public toDataURL(type: string, params: string): string {
140 |
141 | const dpi = window.devicePixelRatio || 1.0;
142 |
143 | this._canvasContainer.scaleX = this._canvasContainer.scaleY = dpi;
144 | this._wrapperForCapure.cache(0, 0, this._data.width * dpi, this._data.height * dpi);
145 |
146 | const capture = this._wrapperForCapure.cacheCanvas;
147 | const dataURL = capture.toDataURL(type, params);
148 | this._wrapperForCapure.uncache();
149 |
150 | this._canvasContainer.scaleX = this._canvasContainer.scaleY = 1.0;
151 |
152 | return dataURL;
153 | }
154 |
155 | /**
156 | * リサイズのイベント処理
157 | */
158 | private resizeHandler(): void {
159 |
160 | let canvasWidth: number = innerWidth;
161 | let canvasHeight: number = innerHeight;
162 |
163 | if (innerWidth > Viewport.sm) {
164 | canvasHeight -= CanvasMargin.TOP_DESKTOP;
165 | canvasWidth -= CanvasMargin.RIGHT_DESKTOP;
166 | this._ruler.container.visible = true;
167 | this._background.visible = true;
168 | this._outerZabuton.visible = true;
169 | } else {
170 | canvasHeight -= CanvasMargin.TOP_MOBILE;
171 | canvasWidth -= CanvasMargin.RIGHT_MOBILE;
172 | this._ruler.container.visible = false;
173 | this._background.visible = false;
174 | this._outerZabuton.visible = false;
175 | }
176 |
177 | const palletW = Math.round(Number(this._data.width));
178 | const palletH = Math.round(Number(this._data.height));
179 |
180 | const canvasX = Math.floor((canvasWidth - palletW) / 2);
181 | const canvasY = Math.floor((canvasHeight - palletH) / 2);
182 |
183 | // ルーラーなどのセンタリング
184 | const canvasPoint = new createjs.Point(canvasX, canvasY);
185 |
186 | this._outerZabuton.graphics
187 | .clear()
188 | .beginFill('rgba(32, 32, 32, 0.7)')
189 | .drawRect(0, 0, canvasWidth, canvasY)
190 | .drawRect(0, canvasY, canvasX, palletH)
191 | .drawRect(canvasX + palletW, canvasY, canvasX, palletH)
192 | .drawRect(0, canvasY + palletH, canvasWidth, canvasY)
193 | .endFill();
194 |
195 | this._wrapperForCapure.x = this._ruler.container.x = canvasPoint.x;
196 | this._wrapperForCapure.y = this._ruler.container.y = canvasPoint.y;
197 |
198 | this._captureImageLayer.x = -canvasPoint.x;
199 | this._captureImageLayer.y = -canvasPoint.y;
200 |
201 | const dpi = window.devicePixelRatio || 1.0;
202 |
203 | // ステージのサイズをwindowのサイズに変更
204 | (this._stage.canvas).width = canvasWidth * dpi;
205 | (this._stage.canvas).height = canvasHeight * dpi;
206 |
207 | this._stage.scaleX = dpi;
208 | this._stage.scaleY = dpi;
209 |
210 | // canvas 要素のスタイルを調整
211 | (this._stage.canvas).style.width = `${canvasWidth}px`;
212 | (this._stage.canvas).style.height = `${canvasHeight}px`;
213 | }
214 |
215 | public update(data: DrawingData): void {
216 |
217 | const palletW = Math.round(Number(this._data.width));
218 | const palletH = Math.round(Number(this._data.height));
219 |
220 | if (palletW !== this._backgroundSize.w
221 | || palletH !== this._backgroundSize.h
222 | || this._backgroundColorCommand.style !== data.bgColor) {
223 | this._backgroundColorCommand.style = data.bgColor;
224 | this._backgroundSize.w = palletW;
225 | this._backgroundSize.h = palletH;
226 | this._ruler.setSize(palletW, palletH);
227 | this.resizeHandler();
228 | }
229 |
230 | this._particleSystem.setData(data);
231 | this._particleSystem.update();
232 | this._ruler.update();
233 | this._stage.update();
234 | }
235 | }
236 |
--------------------------------------------------------------------------------
/src/app/particle/particle-capture-image-layer.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * キャプチャーした画像を配置するレイヤーです。
3 | */
4 | export class ParticleCaptureImageLayer extends createjs.Container {
5 | private _captureImage!: createjs.Bitmap;
6 |
7 | constructor() {
8 | super();
9 | }
10 |
11 | /**
12 | * 画像を追加します。
13 | */
14 | public addImageFromImageData(imageData: string): void {
15 | this.removeImage();
16 |
17 | const base64 = 'data:image/png;base64,' + imageData.replace('file:///', '');
18 |
19 | this._captureImage = new createjs.Bitmap(base64);
20 | this.addChild(this._captureImage);
21 | }
22 |
23 | /**
24 | * URLから画像を追加します。
25 | *
26 | */
27 | public addImageFromURL(imageURL: string): void {
28 | this.removeImage();
29 | this._captureImage = new createjs.Bitmap(imageURL);
30 | this.addChild(this._captureImage);
31 | }
32 |
33 | /**
34 | * 画像を削除します。
35 | */
36 | private removeImage(): void {
37 | if (this.numChildren > 0) {
38 | this.removeAllChildren();
39 | }
40 | }
41 | }
42 |
--------------------------------------------------------------------------------
/src/app/particle/particle-exporter.ts:
--------------------------------------------------------------------------------
1 | declare class SVGExporter {
2 | svg: Node;
3 |
4 | constructor(stage: createjs.Container, width: number, height: number);
5 |
6 | run(): void;
7 | }
8 |
9 | declare let cordova: any;
10 |
11 | /**
12 | * SVG ファイルに出力するクラスです。
13 | */
14 | export class ParticleExporter {
15 |
16 | private _exporter!: SVGExporter;
17 | private _drawLayerContainer: createjs.Container;
18 | private _width!: number;
19 | private _height!: number;
20 |
21 | constructor(drawLayerContainer: createjs.Container) {
22 | this._drawLayerContainer = drawLayerContainer;
23 | }
24 |
25 | public runExport(width: number, height: number): Promise {
26 | this._width = width;
27 | this._height = height;
28 |
29 | return new Promise((onResolve, onReject) => {
30 |
31 | this._exporter = new SVGExporter(this._drawLayerContainer, this._width, this._height);
32 | this._exporter.run();
33 |
34 | setTimeout(() => {
35 | onResolve();
36 | }, 1);
37 | });
38 | }
39 |
40 | public runExportSP(cavas: HTMLCanvasElement): Promise {
41 | return new Promise((onResolve, onReject) => {
42 | const base64 = cavas.toDataURL();
43 | cordova.base64ToGallery(
44 | base64,
45 | 'img_',
46 | function (msg: any) {
47 | onResolve();
48 | },
49 | function (err: any) {
50 | onReject();
51 | }
52 | );
53 | });
54 | }
55 |
56 | public getSvgString(): string {
57 | const serializer = new XMLSerializer();
58 | if (!this._exporter) {
59 | throw new Error();
60 | }
61 | return serializer.serializeToString(this._exporter.svg);
62 | }
63 | }
64 |
--------------------------------------------------------------------------------
/src/app/particle/particle-image-importer.ts:
--------------------------------------------------------------------------------
1 | declare var Camera: any;
2 | declare namespace navigator {
3 | export let camera: any;
4 | }
5 |
6 | /**
7 | * 画像を読み込むクラスです
8 | */
9 | export class PartcicleImageImporter {
10 | constructor() {
11 | }
12 |
13 | /**
14 | * ネイティブ機能を使ってカメラを撮影します。
15 | */
16 | public getCapture(canvasWidth: number, canvasHeight: number): Promise {
17 | return new Promise((onResolve, onReject) => {
18 | navigator.camera.getPicture(
19 | (imageData: string) => this.cameraSuccessHandler(imageData, onResolve),
20 | (errorMessage: string) => this.cameraFailHandler(errorMessage, onReject),
21 | {
22 | quality : 70,
23 | destinationType : Camera.DestinationType.DATA_URL,
24 | targetWidth : canvasWidth,
25 | targetHeight : canvasHeight,
26 | correctOrientation: true,
27 | encodingType : Camera.EncodingType.PNG
28 | }
29 | );
30 | });
31 | }
32 |
33 | /**
34 | * カメラ撮影に成功した時
35 | */
36 | private cameraSuccessHandler(imageData: string, onResolve: Function): void {
37 | onResolve(imageData);
38 | }
39 |
40 | /**
41 | * カメラ撮影に失敗した時
42 | */
43 | private cameraFailHandler(errorMessage: string, onReject: Function): void {
44 | alert('カメラの起動に失敗しました。');
45 | onReject();
46 | }
47 | }
48 |
--------------------------------------------------------------------------------
/src/app/particle/particle-ruler.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * キャンバスに表示するルーラーの制御クラスです。
3 | */
4 | import {DrawingData} from 'particlejs';
5 |
6 | export class Ruler {
7 |
8 | private FONT_COLOR = '#444';
9 |
10 | public container: createjs.Container;
11 | private _shapeBg: createjs.Shape;
12 | private _shapeMouse: createjs.Shape;
13 | private _verticalTextList: createjs.Text[];
14 | private _horizontalTextList: createjs.Text[];
15 | private _width!: number;
16 | private _height!: number;
17 | private _thumb: createjs.Shape;
18 | private _isMouseDown = false;
19 |
20 | constructor(private _data: DrawingData) {
21 | this.container = new createjs.Container();
22 | this._shapeBg = new createjs.Shape();
23 | this.container.addChild(this._shapeBg);
24 |
25 | this._shapeMouse = new createjs.Shape();
26 | this.container.addChild(this._shapeMouse);
27 |
28 | this._thumb = new createjs.Shape();
29 | this._thumb.cursor = 'crosshair';
30 | this._thumb.graphics.setStrokeStyle(3)
31 | .beginStroke('white').drawRect(-8, -8, 16, 16).endStroke()
32 | .beginStroke('black').drawRect(-6, -6, 12, 12).endStroke()
33 | .beginFill('rgba(0, 0, 0, 0.01)').drawRect(-24, -24, 48, 48);
34 | this.container.addChild(this._thumb);
35 |
36 | this.container.on('mousedown', () => {
37 | this._isMouseDown = true;
38 | });
39 | this.container.on('pressmove', this.handleThumbMouseMove, this);
40 | this.container.on('pressup', () => {
41 | this._isMouseDown = false;
42 | });
43 |
44 | this._verticalTextList = [];
45 | this._horizontalTextList = [];
46 | }
47 |
48 | private handleThumbMouseMove(): void {
49 | const stage = this.container.stage;
50 | const point = this.container.globalToLocal(stage.mouseX, stage.mouseY);
51 |
52 | this._thumb.x = point.x;
53 | this._thumb.y = point.y;
54 |
55 | // データに反映
56 | this._data.startX = point.x;
57 | this._data.startY = point.y;
58 | }
59 |
60 | public setSize(ws: number, hs: number): void {
61 | this._width = ws;
62 | this._height = hs;
63 |
64 |
65 | const graphics = this._shapeBg.graphics;
66 | graphics.clear();
67 | graphics.setStrokeStyle(1);
68 | graphics.beginStroke(this.FONT_COLOR);
69 |
70 | // 枠線を描く
71 | graphics.drawRect(-0.5, -0.5, ws + 1.0, hs + 1.0);
72 |
73 | const distance = 35;
74 | const w: number = Math.floor(this._width / distance);
75 | const h: number = Math.floor(this._height / distance);
76 |
77 | for (let i = 0; i < w; i++) {
78 | const ii = (i);
79 | if (this._horizontalTextList.length <= ii) {
80 | this._horizontalTextList.push(new createjs.Text((i * distance) + '', 'Arial 20px', this.FONT_COLOR));
81 | }
82 | this._horizontalTextList[ii].visible = true;
83 | this._horizontalTextList[ii].x = (i * distance);
84 | this._horizontalTextList[ii].y = -20;
85 | this._horizontalTextList[ii].rotation = -90;
86 | this._horizontalTextList[ii].textAlign = 'center';
87 | this._horizontalTextList[ii].textBaseline = 'middle';
88 | this.container.addChild(this._horizontalTextList[ii]);
89 |
90 | graphics.moveTo((i * distance), -5);
91 | graphics.lineTo((i * distance), 0);
92 | }
93 | for (let i = w; i < this._horizontalTextList.length; i++) {
94 | this._horizontalTextList[i].visible = false;
95 | }
96 |
97 | for (let i = 0; i < h; i++) {
98 | const ii = (i);
99 | if (this._verticalTextList.length <= ii) {
100 | this._verticalTextList.push(new createjs.Text((i * distance) + '', 'Arial 20px', this.FONT_COLOR));
101 | }
102 | this._verticalTextList[ii].visible = true;
103 | this._verticalTextList[ii].y = (i * distance);
104 | this._verticalTextList[ii].x = -20;
105 | this._verticalTextList[ii].textAlign = 'right';
106 | this._verticalTextList[ii].textBaseline = 'middle';
107 | this.container.addChild(this._verticalTextList[ii]);
108 |
109 | graphics.moveTo(-5, (i * distance));
110 | graphics.lineTo(0, (i * distance));
111 | }
112 |
113 | for (let i = h; i < this._verticalTextList.length; i++) {
114 | this._verticalTextList[i].visible = false;
115 | }
116 |
117 |
118 | }
119 |
120 | public update() {
121 | const stage = this.container.stage;
122 |
123 | const mousePt = this.container.globalToLocal(stage.mouseX, stage.mouseY);
124 | const graphics = this._shapeMouse.graphics;
125 |
126 | graphics.clear()
127 | .setStrokeStyle(2)
128 | .beginStroke('#6699ff');
129 |
130 | const isInHorizontal: boolean = 0 <= mousePt.x && mousePt.x <= this._width;
131 | const isInVertical: boolean = 0 <= mousePt.y && mousePt.y <= this._height;
132 |
133 | if (isInHorizontal === true) {
134 | graphics.moveTo(mousePt.x, 0);
135 | graphics.lineTo(mousePt.x, -16);
136 | }
137 |
138 | if (isInVertical === true) {
139 | graphics.moveTo(-16, mousePt.y);
140 | graphics.lineTo(0, mousePt.y);
141 | }
142 |
143 | // ドラッグ中でなければ、かっこ良く目盛りを表示する
144 | if (this._isMouseDown === true) {
145 |
146 | const mx: number = Math.floor(mousePt.x) - 0.5;
147 | const my: number = Math.floor(mousePt.y) - 0.5;
148 |
149 | graphics
150 | .setStrokeStyle(1)
151 | .beginStroke(createjs.Graphics.getRGB(255, 255, 255, 0.5));
152 |
153 | if (isInHorizontal === true) {
154 | graphics.moveTo(mx, 0);
155 | graphics.lineTo(mx, this._data.height);
156 | }
157 |
158 | if (isInVertical === true) {
159 | graphics.moveTo(0, my);
160 | graphics.lineTo(this._data.width, my);
161 | }
162 | } else {
163 | // ドラッグ中でなければ、データを反映
164 | this._thumb.x = this._data.startX;
165 | this._thumb.y = this._data.startY;
166 | }
167 | }
168 | }
169 |
--------------------------------------------------------------------------------
/src/assets/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/src/assets/favicon.ico
--------------------------------------------------------------------------------
/src/assets/images/particle-template/basic.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/src/assets/images/particle-template/basic.png
--------------------------------------------------------------------------------
/src/assets/images/particle-template/blue_light.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/src/assets/images/particle-template/blue_light.png
--------------------------------------------------------------------------------
/src/assets/images/particle-template/commet.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/src/assets/images/particle-template/commet.png
--------------------------------------------------------------------------------
/src/assets/images/particle-template/fire.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/src/assets/images/particle-template/fire.png
--------------------------------------------------------------------------------
/src/assets/images/particle-template/graphic.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/src/assets/images/particle-template/graphic.png
--------------------------------------------------------------------------------
/src/assets/images/particle-template/green_kirakira.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/src/assets/images/particle-template/green_kirakira.png
--------------------------------------------------------------------------------
/src/assets/images/particle-template/heart_world.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/src/assets/images/particle-template/heart_world.png
--------------------------------------------------------------------------------
/src/assets/images/particle-template/light_ball.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/src/assets/images/particle-template/light_ball.png
--------------------------------------------------------------------------------
/src/assets/images/particle-template/parple.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/src/assets/images/particle-template/parple.png
--------------------------------------------------------------------------------
/src/assets/images/particle-template/snow.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/src/assets/images/particle-template/snow.png
--------------------------------------------------------------------------------
/src/assets/images/particle-template/spirit.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/src/assets/images/particle-template/spirit.png
--------------------------------------------------------------------------------
/src/assets/images/particle-template/star.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/src/assets/images/particle-template/star.png
--------------------------------------------------------------------------------
/src/assets/images/preview.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/src/assets/images/preview.png
--------------------------------------------------------------------------------
/src/assets/images/ui/about.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/src/assets/images/ui/about.png
--------------------------------------------------------------------------------
/src/assets/images/ui/copyright.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/src/assets/images/ui/copyright.png
--------------------------------------------------------------------------------
/src/assets/images/ui/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/src/assets/images/ui/logo.png
--------------------------------------------------------------------------------
/src/assets/images/ui/logo_512x512.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/src/assets/images/ui/logo_512x512.png
--------------------------------------------------------------------------------
/src/assets/images/ui/logo_angular2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/src/assets/images/ui/logo_angular2.png
--------------------------------------------------------------------------------
/src/assets/images/ui/logo_base_apple.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ics-creative/project-particle-develop/273acaab3efd45b5a3734244978205a770d932b8/src/assets/images/ui/logo_base_apple.png
--------------------------------------------------------------------------------
/src/assets/images/ui/logo_createjs.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
54 |
--------------------------------------------------------------------------------
/src/embeds/images/md-arrow-dropdown.svg:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/src/embeds/js/particlejs.min.js:
--------------------------------------------------------------------------------
1 | !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.particlejs=t():e.particlejs=t()}(window,function(){return a={},n.m=i=[function(e,t,i){e.exports=i(1)},function(e,t,i){"use strict";i.r(t);var a,n,r,o={},s=window.createjs;a=o=o||{},n=s=s||{},a.properties={width:550,height:400,fps:24,color:"#999999",manifest:[]},(a.triangle=function(){this.initialize(),this.shape=new n.Shape,this.shape.graphics.beginFill("#FFFFFF").beginStroke().moveTo(-.7,-27.8).lineTo(32,27.1).lineTo(-32,27.8).closePath(),this.shape.setTransform(0,-7),this.addChild(this.shape)}).prototype=r=new n.Container,r.nominalBounds=new n.Rectangle(-32,-34.8,64,55.7),(a.star_10=function(){this.initialize(),this.shape=new n.Shape,this.shape.graphics.beginFill("#FFFFFF").beginStroke().moveTo(-4.3,18.3).lineTo(-19.9,29.3).lineTo(-14.1,10.3).lineTo(-32,10.3).lineTo(-19.7,.7).lineTo(-31.2,-8.7).lineTo(-15.2,-8.8).lineTo(-21.7,-26.4).lineTo(-5.4,-16.4).lineTo(-.2,-31.8).lineTo(4.4,-17.6).lineTo(17.8,-27.4).lineTo(13.1,-8.5).lineTo(30.3,-8.1).lineTo(19.9,.1).lineTo(32,8.4).lineTo(12.8,9.5).lineTo(18.2,29.8).lineTo(4.9,20).lineTo(1.4,31.8).closePath(),this.addChild(this.shape)}).prototype=r=new n.Container,r.nominalBounds=new n.Rectangle(-32,-31.7,64,63.6),(a.star=function(){this.initialize(),this.shape=new n.Shape,this.shape.graphics.beginFill("#FFFFFF").beginStroke().moveTo(-.2,17.3).lineTo(-20.2,31.5).lineTo(-13,7.4).lineTo(-32,-8).lineTo(-7.8,-8.4).lineTo(.3,-32).lineTo(8,-8.2).lineTo(32,-7.4).lineTo(12.8,7.5).lineTo(19.4,32).closePath(),this.addChild(this.shape)}).prototype=r=new n.Container,r.nominalBounds=new n.Rectangle(-32,-32,64,64),(a.square=function(){this.initialize(),this.shape=new n.Shape,this.shape.graphics.beginFill().beginStroke("#FFFFFF").setStrokeStyle(8,1,1).moveTo(-32,-32).lineTo(32,-32).lineTo(32,32).lineTo(-32,32).closePath(),this.addChild(this.shape)}).prototype=r=new n.Container,r.nominalBounds=new n.Rectangle(-36,-36,72,72),(a.reverse_blur_circle=function(){this.initialize(),this.shape=new n.Shape,this.shape.graphics.beginFill().beginStroke("#FFFFFF").setStrokeStyle(8,1,1).moveTo(32,0).curveTo(32,13.2,22.6,22.6).curveTo(13.3,32,0,32).curveTo(-13.2,32,-22.7,22.6).curveTo(-32,13.2,-32,0).curveTo(-32,-13.3,-22.7,-22.7).curveTo(-13.2,-32,0,-32).curveTo(13.3,-32,22.6,-22.7).curveTo(32,-13.3,32,0).closePath(),this.addChild(this.shape)}).prototype=r=new n.Container,r.nominalBounds=new n.Rectangle(-36,-36,72,72),(a.kirakira2=function(){this.initialize(),this.shape=new n.Shape,this.shape.graphics.beginFill("#FFFFFF").beginStroke().moveTo(-4,9.5).curveTo(-7.8,0,-13.4,-.1).curveTo(-7.8,-.2,-4,-9.9).curveTo(-.1,-19.2,0,-32).curveTo(.1,-19.2,4,-9.9).curveTo(8,-.2,13.4,-.1).curveTo(8,0,4,9.5).curveTo(.1,19,0,32).curveTo(-.1,19,-4,9.5).closePath(),this.addChild(this.shape)}).prototype=r=new n.Container,r.nominalBounds=new n.Rectangle(-13.4,-32,26.8,64),(a.kirakira=function(){this.initialize(),this.shape=new n.Shape,this.shape.graphics.beginFill("#FFFFFF").beginStroke().moveTo(-9.6,9.3).curveTo(-18.9,0,-32,-.1).curveTo(-18.9,-.2,-9.6,-9.6).curveTo(-.2,-19,-.1,-32).curveTo(0,-19,9.4,-9.6).curveTo(18.9,-.2,32,-.1).curveTo(18.9,0,9.4,9.3).curveTo(0,18.8,-.1,32).curveTo(-.2,18.8,-9.6,9.3).closePath(),this.addChild(this.shape)}).prototype=r=new n.Container,r.nominalBounds=new n.Rectangle(-32,-32,64,64),(a.heart=function(){this.initialize(),this.shape=new n.Shape,this.shape.graphics.beginFill("#FFFFFF").beginStroke().moveTo(-20.2,10).lineTo(-24.8,3.5).curveTo(-27,.1,-28.5,-3.1).curveTo(-30.1,-6.4,-31.1,-9.5).curveTo(-32,-13,-32,-16).curveTo(-32,-19.7,-30.4,-22.7).curveTo(-29.1,-25.4,-26.6,-27.4).curveTo(-24,-29.1,-21,-30.1).curveTo(-18.1,-31.1,-15,-31.1).curveTo(-11.7,-31.1,-8.8,-29.9).curveTo(-6.4,-29,-4.5,-27.4).curveTo(-3,-25.9,-1.7,-23.9).lineTo(0,-20.8).lineTo(1.7,-23.9).curveTo(3,-25.9,4.5,-27.4).curveTo(6.6,-29.1,8.8,-29.9).curveTo(11.7,-31.1,15.2,-31.1).curveTo(18.4,-31.1,21.3,-30.1).curveTo(24.2,-29.1,26.7,-27.2).curveTo(29.1,-25.3,30.5,-22.6).curveTo(32,-19.7,32,-16.1).curveTo(32,-13.3,31,-9.7).curveTo(30.2,-6.5,28.5,-3.2).curveTo(27.1,0,24.9,3.3).lineTo(20.3,9.7).curveTo(13.4,17.7,9.7,21.6).lineTo(0,31).curveTo(-13.6,18.3,-20.2,10).closePath(),this.addChild(this.shape)}).prototype=r=new n.Container,r.nominalBounds=new n.Rectangle(-32,-31,64,62.1),(a.flower=function(){this.initialize(),this.shape=new n.Shape,this.shape.graphics.beginFill("#FFFFFF").beginStroke().moveTo(4,27.3).curveTo(.5,23.7,.5,18.9).lineTo(.5,15.2).lineTo(-.5,15.2).lineTo(-.7,18.9).curveTo(-.9,24,-4.1,27.6).curveTo(-7.4,31.1,-12.1,31.1).curveTo(-17,31.1,-20.8,27.5).curveTo(-24.7,23.7,-24.7,19.1).curveTo(-24.7,15.3,-22.2,12.1).curveTo(-19.7,8.8,-16.1,7.7).lineTo(-12.5,6.4).lineTo(-12.7,5.8).lineTo(-13,5.4).lineTo(-16.5,6.6).lineTo(-20.2,7.1).curveTo(-25.3,7.1,-28.7,4).curveTo(-32,.7,-32,-4.1).curveTo(-32,-9.4,-28.7,-13).curveTo(-25.5,-16.8,-20.6,-16.8).curveTo(-17.8,-16.8,-15,-15.4).curveTo(-12.2,-14,-10.5,-11.6).lineTo(-8.4,-8.7).lineTo(-8,-8.8).lineTo(-7.4,-9.3).lineTo(-9.6,-12.2).curveTo(-10.7,-14,-11.3,-15.8).curveTo(-11.9,-17.9,-12,-19.9).curveTo(-12,-24.7,-8.5,-28).curveTo(-5.3,-31.1,-.1,-31.1).curveTo(5.2,-31.1,8.5,-28).curveTo(11.7,-24.7,11.8,-19.9).curveTo(11.7,-17.7,11.2,-15.7).curveTo(10.7,-13.8,9.5,-12.2).lineTo(7.4,-9.3).lineTo(7.8,-9).lineTo(8.2,-8.7).lineTo(10.5,-11.6).curveTo(12.2,-14,14.8,-15.4).curveTo(17.6,-16.8,20.4,-16.8).curveTo(25.3,-16.8,28.5,-13).curveTo(32,-9.4,32,-4.1).curveTo(32,.8,28.5,4).curveTo(25.3,7.1,20,7.1).lineTo(16.4,6.6).lineTo(12.9,5.5).curveTo(12.8,5.6,12.8,5.6).curveTo(12.7,5.7,12.7,5.7).curveTo(12.7,5.8,12.7,5.8).curveTo(12.7,5.9,12.7,6).lineTo(12.5,6.4).lineTo(15.9,7.7).curveTo(19.7,9.1,22.1,12.2).curveTo(24.5,15.3,24.5,19.1).curveTo(24.5,23.7,20.8,27.5).curveTo(16.9,31.1,11.9,31.1).curveTo(7.4,31.1,4,27.3).closePath().moveTo(-7.7,-5.9).curveTo(-10.9,-2.7,-10.9,1.8).curveTo(-10.9,6.3,-7.7,9.4).curveTo(-4.6,12.5,-.1,12.5).curveTo(4.4,12.5,7.6,9.4).curveTo(10.6,6.3,10.6,1.8).curveTo(10.6,-2.7,7.6,-5.9).curveTo(4.4,-9,-.1,-9).curveTo(-4.6,-9,-7.7,-5.9).closePath(),this.addChild(this.shape)}).prototype=r=new n.Container,r.nominalBounds=new n.Rectangle(-32,-31,64,62.2),(a.circle=function(){this.initialize(),this.shape=new n.Shape,this.shape.graphics.beginFill("#FFFFFF").beginStroke().drawEllipse(-10.8,-10.8,21.7,21.7),this.shape.setTransform(0,0,2.949,2.949),this.addChild(this.shape)}).prototype=r=new n.Container,r.nominalBounds=new n.Rectangle(-32,-32,64,64),(a.blur_circle=function(){this.initialize(),this.shape=new n.Shape,this.shape.graphics.beginRadialGradientFill(["#FFFFFF","rgba(255,255,255,0)"],[0,1],0,0,0,0,0,11).beginStroke().drawEllipse(-10.8,-10.8,21.7,21.7),this.shape.setTransform(0,0,3,3),this.addChild(this.shape)}).prototype=r=new n.Container,r.nominalBounds=new n.Rectangle(-32.5,-32.5,65.1,65.1),(a.assetshapes=function(){this.initialize(),this.instance=new a.triangle,this.instance.setTransform(323.6,39.6),this.instance_1=new a.square,this.instance_1.setTransform(518,151.5),this.instance_2=new a.kirakira2,this.instance_2.setTransform(420.8,32.6),this.instance_3=new a.kirakira,this.instance_3.setTransform(32,151.5),this.instance_4=new a.flower,this.instance_4.setTransform(396.5,151.5),this.instance_5=new a.star_10,this.instance_5.setTransform(518,32.6),this.instance_6=new a.star,this.instance_6.setTransform(275,151.5),this.instance_7=new a.circle,this.instance_7.setTransform(226.4,32.6),this.instance_8=new a.reverse_blur_circle,this.instance_8.setTransform(153.5,151.5),this.instance_9=new a.blur_circle,this.instance_9.setTransform(129.2,32.6),this.instance_10=new a.heart,this.instance_10.setTransform(32,32.6),this.addChild(this.instance_10,this.instance_9,this.instance_8,this.instance_7,this.instance_6,this.instance_5,this.instance_4,this.instance_3,this.instance_2,this.instance_1,this.instance)}).prototype=r=new n.Container,r.nominalBounds=new n.Rectangle(275,200,554,187.5);var c=(l.prototype.generateShape=function(e){return new o[e]},l);function l(){}var h,u,p=function(){this.hue=0,this.hueVariance=0,this.saturation=0,this.saturationVariance=0,this.luminance=0,this.luminanceVariance=0};(u=h=h||{})[u.Normal=0]="Normal",u[u.Random=1]="Random";var f=(d.prototype.importFromJson=function(e){this.setData(e,function(e){return"width"==e||"height"==e||"bgColor"==e})},d.prototype.importData=function(e){this.setData(e,function(e){return"width"==e||"height"==e||"startX"==e||"startY"==e})},d.checkReflectEnable=function(){try{return!(!Reflect||!Reflect.has)}catch(e){return!1}},d.prototype.setData=function(e,t){if(d.ENABLE_REFLECT){for(var i in e)if(!t(i)&&1==Reflect.has(this,i)){var a=e[i];Reflect.set(this,i,a)}}else for(var i in e)t(i)||this.hasOwnProperty(i)&&(this[i]=e[i])},d.ENABLE_REFLECT=d.checkReflectEnable(),d);function d(e){void 0===e&&(e=null),this.bgColor="",this.width=0,this.height=0,this.emitFrequency=0,this.startX=0,this.startXVariance=0,this.startY=0,this.startYVariance=0,this.initialDirection=0,this.initialDirectionVariance=0,this.initialSpeed=0,this.initialSpeedVariance=0,this.friction=0,this.accelerationSpeed=0,this.accelerationDirection=0,this.startScale=0,this.startScaleVariance=0,this.finishScale=0,this.finishScaleVariance=0,this.lifeSpan=0,this.lifeSpanVariance=0,this.startAlpha=0,this.startAlphaVariance=0,this.finishAlpha=0,this.finishAlphaVariance=0,this.shapeIdList=[""],this.startColor=new p,this.blendMode=!0,this.alphaCurveType=h.Normal,e&&this.importFromJson(e)}function g(){this.assetList=["blur_circle","circle","flower","heart","kirakira","kirakira2","reverse_blur_circle","square","star","star_10","triangle"]}var v=(T.BLUR_CIRCLE="blur_circle",T.CIRCLE="circle",T.FLOWER="flower",T.HEART="heart",T.KIRAKIRA="kirakira",T.KIRAKIRA2="kirakira2",T.REVERSE_CIRCLE="reverse_blur_circle",T.SQUARE="square",T.STAR="star",T.STAR_10="star_10",T.TRIANGLE="triangle",T);function T(){}var _=function(){this.particleShape=new createjs.Container,this.startColor=new p},m="1.0.0";var w=(b.prototype.isPlaying=function(){return this._playing},b.prototype.setData=function(e){this._drawingData=e},b.prototype.importFromJson=function(e){!function(e){var t=m.split(".");if(t.length<=2)return console.log("バージョン表記エラーが発生しました。"),!1;if(!e)return"0"==t[0]&&"1"==t[1];var i=e.split(".");return t[0]==i[0]&&t[1]==i[1]}(e.VERSION||"")&&console.warn("読み込んだJSONファイルとParticleJSのバージョンが異なります。\nhttps://github.com/ics-creative/ParticleJS"),this._drawingData.importFromJson(e)},b.prototype.update=function(){this._playing&&(this.emit(),this.animate(),this.lifeCheck())},b.prototype.animate=function(){for(var e=createjs.Matrix2D.DEG_TO_RAD*this._drawingData.accelerationDirection,t=Math.cos(e)*this._drawingData.accelerationSpeed,i=Math.sin(e)*this._drawingData.accelerationSpeed,a=0;a=e&&(this._frameCount=0)},b.prototype.emitParticle=function(){var e=this.generateParticle();this.container.addChild(e.particleShape),this._activeParticles.push(e)},b.prototype.generateParticle=function(){var e=null;return e=1<=this._particlesPool.length?this._particlesPool.shift():new _,this.setParticleParameter(e),e},b.prototype.setParticleParameter=function(e){e.particleShape.removeAllChildren(),e.isAlive=!0,e.x=this.calcRandomValueWithVariance(this._drawingData.startX,this._drawingData.startXVariance,!1),e.y=this.calcRandomValueWithVariance(this._drawingData.startY,this._drawingData.startYVariance,!1),this.generateShape(e,this._drawingData.shapeIdList),e.totalLife=Math.max(1,this.calcRandomValueWithVariance(this._drawingData.lifeSpan,this._drawingData.lifeSpanVariance,!0)),e.currentLife=e.totalLife;var t=Math.max(0,this.calcRandomValueWithVariance(this._drawingData.initialSpeed,this._drawingData.initialSpeedVariance,!1)),i=createjs.Matrix2D.DEG_TO_RAD*this.calcRandomValueWithVariance(this._drawingData.initialDirection,this._drawingData.initialDirectionVariance,!1);e.vx=Math.cos(i)*t,e.vy=Math.sin(i)*t,e.startAlpha=this.calcRandomValueWithRange(0,1,this.calcRandomValueWithVariance(this._drawingData.startAlpha,this._drawingData.startAlphaVariance,!1)),e.finishAlpha=this.calcRandomValueWithRange(0,1,this.calcRandomValueWithVariance(this._drawingData.finishAlpha,this._drawingData.finishAlphaVariance,!1)),e.startScale=Math.max(0,this.calcRandomValueWithVariance(this._drawingData.startScale,this._drawingData.startScaleVariance,!1)),e.finishScale=Math.max(0,this.calcRandomValueWithVariance(this._drawingData.finishScale,this._drawingData.finishScaleVariance,!1)),e.particleShape.compositeOperation=1==this._drawingData.blendMode?"lighter":null,e.alphaCurveType=this._drawingData.alphaCurveType},b.prototype.generateShape=function(e,t){e.particleShape.removeAllChildren();var i=this._drawingData.startColor;e.startColor.hue=this.calcRandomValueWithVariance(i.hue,i.hueVariance,!1)%360,e.startColor.luminance=this.calcRandomValueWithVariance(i.luminance,i.luminanceVariance,!1),e.startColor.saturation=this.calcRandomValueWithVariance(i.saturation,i.saturationVariance,!1);var a=Number(e.startColor.hue),n=Number(e.startColor.saturation),r=Number(e.startColor.luminance),o="hsl("+a+", "+n+"%, "+r+"%)",s=Math.floor(Math.random()*this._drawingData.shapeIdList.length),c=0==this._drawingData.shapeIdList.length?"":this._drawingData.shapeIdList[s];e.colorCommand=null;var l=this.shapeGenerator.generateShape(c);e.particleShape.addChild(l);var h=l.getChildAt(0);if(null!=h){var u=h.graphics.instructions;if(u&&0
146 |
147 | examples:
148 | mobile range: http://codepen.io/Topcoat/pen/BskEn
149 | tags:
150 | - desktop
151 | - mobile
152 | - range
153 | */
154 |
155 | .topcoat-range {
156 | border-radius: 4px;
157 | border: 1px solid #333434;
158 | background-color: #454646;
159 | height: 0.7rem;
160 | border-radius: 15px;
161 | }
162 |
163 | .topcoat-range::-moz-range-track {
164 | border-radius: 4px;
165 | border: 1px solid #333434;
166 | background-color: #454646;
167 | height: 1.0rem;
168 | border-radius: 15px;
169 | }
170 |
171 | .topcoat-range::-webkit-slider-thumb {
172 | height: 16px;
173 | width: 16px;
174 | background-image: linear-gradient(to top, #7b8491, #c8dde6);
175 | border: 1px solid #333434;
176 | border-radius: 50%;
177 | box-shadow: inset 0 1px #737373;
178 | }
179 |
180 | .topcoat-range::-moz-range-thumb {
181 | height: 12px;
182 | width: 12px;
183 | background-color: #777f8d;
184 | border: 1px solid #333434;
185 | border-radius: 50%;
186 | box-shadow: inset 0 1px #737373;
187 | }
188 |
189 | .topcoat-range:focus::-webkit-slider-thumb {
190 | border: 1px solid #0036ff;
191 | box-shadow: inset 0 1px rgba(255, 255, 255, 0.36), 0 0 0 2px #6fb5f1;
192 | }
193 |
194 | .topcoat-range:focus::-moz-range-thumb {
195 | border: 1px solid #0036ff;
196 | box-shadow: inset 0 1px rgba(255, 255, 255, 0.36), 0 0 0 2px #6fb5f1;
197 | }
198 |
199 | .topcoat-range:active::-webkit-slider-thumb {
200 | border: 1px solid #333434;
201 | box-shadow: inset 0 1px #737373;
202 | }
203 |
204 | .topcoat-range:active::-moz-range-thumb {
205 | border: 1px solid #333434;
206 | box-shadow: inset 0 1px #737373;
207 | }
208 |
209 | /**
210 | *
211 | * Copyright 2012 Adobe Systems Inc.;
212 | *
213 | * Licensed under the Apache License, Version 2.0 (the "License");
214 | * you may not use this file except in compliance with the License.
215 | * You may obtain a copy of the License at
216 | *
217 | * http://www.apache.org/licenses/LICENSE-2.0
218 | *
219 | * Unless required by applicable law or agreed to in writing, software
220 | * distributed under the License is distributed on an "AS IS" BASIS,
221 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
222 | * See the License for the specific language governing permissions and
223 | * limitations under the License.
224 | *
225 | */
226 |
227 | .topcoat-text-input,
228 | .topcoat-text-input--large {
229 | line-height: 1.313rem;
230 | font-size: 12px;
231 | letter-spacing: 0;
232 | padding: 0 0.563rem;
233 | border: 1px solid #333434;
234 | border-radius: 4px;
235 | background-color: #454646;
236 | box-shadow: inset 0 1px rgba(0, 0, 0, 0.05);
237 | color: #c6c8c8;
238 | vertical-align: top;
239 |
240 | /* 自前で追加 */
241 | width: 100%;
242 | }
243 |
244 | .topcoat-text-input:focus,
245 | .topcoat-text-input--large:focus {
246 | background-color: #595b5b;
247 | color: #fff;
248 | border: 1px solid #0036ff;
249 | box-shadow: 0 0 0 2px #6fb5f1;
250 | }
251 |
252 | .topcoat-text-input:disabled::-webkit-input-placeholder {
253 | color: #fff;
254 | }
255 |
256 | .topcoat-text-input:disabled::-moz-placeholder {
257 | color: #fff;
258 | }
259 |
260 | .topcoat-text-input:disabled:-ms-input-placeholder {
261 | color: #fff;
262 | }
263 |
264 | .topcoat-text-input:invalid {
265 | border: 1px solid #ec514e;
266 | }
267 |
268 | .topcoat-checkbox__checkmark {
269 | height: 1rem;
270 | }
271 |
272 | input[type="checkbox"] {
273 | height: 1rem;
274 | width: 1rem;
275 | margin-top: 0;
276 | /*margin-right: -1rem;*/
277 | margin-bottom: -1rem;
278 | margin-left: 0;
279 | }
280 |
281 | input[type="checkbox"]:checked + .topcoat-checkbox__checkmark:after {
282 | opacity: 1;
283 | }
284 |
285 | .topcoat-checkbox {
286 | line-height: 1rem;
287 | }
288 |
289 | .topcoat-checkbox__checkmark:before {
290 | width: 1rem;
291 | height: 1rem;
292 | background: #595b5b;
293 | border: 1px solid #333434;
294 | border-radius: 3px;
295 | box-shadow: inset 0 1px #737373;
296 | }
297 |
298 | .topcoat-checkbox__checkmark {
299 | width: 1rem;
300 | height: 1rem;
301 | }
302 |
303 | .topcoat-checkbox__checkmark:after {
304 | top: 2px;
305 | left: 1px;
306 | opacity: 0;
307 | width: 14px;
308 | height: 4px;
309 | background: transparent;
310 | border: 7px solid #c6c8c8;
311 | border-width: 3px;
312 | border-top: none;
313 | border-right: none;
314 | border-radius: 1px;
315 | -webkit-transform: rotate(-50deg);
316 | -ms-transform: rotate(-50deg);
317 | transform: rotate(-50deg);
318 | }
319 |
320 | input[type="checkbox"]:focus + .topcoat-checkbox__checkmark:before {
321 | border: 1px solid #0036ff;
322 | box-shadow: inset 0 1px rgba(255, 255, 255, 0.36), 0 0 0 2px #6fb5f1;
323 | }
324 |
325 | input[type="checkbox"]:active + .topcoat-checkbox__checkmark:before {
326 | border: 1px solid #333434;
327 | background-color: #3f4041;
328 | box-shadow: inset 0 1px rgba(0, 0, 0, 0.05);
329 | }
330 |
331 | input[type="checkbox"]:disabled:active + .topcoat-checkbox__checkmark:before {
332 | border: 1px solid #333434;
333 | background: #595b5b;
334 | box-shadow: inset 0 1px #737373;
335 | }
336 |
337 | .button--disabled,
338 | .topcoat-icon-button:disabled,
339 | .topcoat-icon-button--quiet:disabled,
340 | .topcoat-icon-button--large:disabled,
341 | .topcoat-icon-button--large--quiet:disabled {
342 | opacity: 0.3;
343 | cursor: default;
344 | pointer-events: none;
345 | }
346 |
347 | .topcoat-select {
348 | margin: 0;
349 | font: inherit;
350 | background: 0 0;
351 | outline: 0;
352 | -moz-box-sizing: border-box;
353 | box-sizing: border-box;
354 | background-clip: padding-box;
355 | position: relative;
356 | display: inline-block;
357 | vertical-align: top
358 | }
359 |
360 | .topcoat-select:disabled {
361 | opacity: .3;
362 | cursor: default;
363 | pointer-events: none
364 | }
365 |
366 | .topcoat-select {
367 | -moz-appearance: none;
368 | -webkit-appearance: none
369 | }
370 |
371 | .topcoat-select::-ms-expand {
372 | display: none
373 | }
374 |
375 | .topcoat-select {
376 | -webkit-user-select: none;
377 | -moz-user-select: none;
378 | -ms-user-select: none;
379 | user-select: none;
380 | cursor: pointer;
381 | appearance: button;
382 | text-indent: .01px;
383 | text-overflow: '';
384 | padding: .06rem 1.4rem .06rem .4rem;
385 | font-size: 12px;
386 | font-weight: 400;
387 | height: 1.813rem;
388 | letter-spacing: 0;
389 | color: hsla(180, 2%, 78%, 1);
390 | text-shadow: 0 -1px hsla(0, 0%, 0%, .69);
391 | border-radius: 4px;
392 | background-color: hsla(180, 1%, 35%, 1);
393 | box-shadow: inset 0 1px hsla(0, 0%, 45%, 1);
394 | border: 1px solid hsla(180, 1%, 20%, 1);
395 | background-image: url(../images/md-arrow-dropdown.svg);
396 | background-repeat: no-repeat;
397 | background-position: center right;
398 | min-width: 3.4rem
399 | }
400 |
401 | .topcoat-select:hover {
402 | background-color: hsla(200, 2%, 39%, 1)
403 | }
404 |
405 | .topcoat-select:active {
406 | background-color: hsla(210, 2%, 25%, 1);
407 | box-shadow: inset 0 1px hsla(0, 0%, 0%, .05)
408 | }
409 |
410 | .topcoat-select:focus {
411 | border: 1px solid hsla(227, 100%, 50%, 1);
412 | box-shadow: 0 0 0 2px hsla(208, 82%, 69%, 1);
413 | outline: 0
414 | }
415 |
--------------------------------------------------------------------------------
/src/embeds/typings/index.d.ts:
--------------------------------------------------------------------------------
1 | ///
2 |
3 |
4 |
--------------------------------------------------------------------------------
/src/embeds/typings/other/index.d.ts:
--------------------------------------------------------------------------------
1 |
2 | declare class NavigatorTmp {
3 | browserLanguage: string;
4 | userLanguage: string;
5 | languages: any;
6 | language: string;
7 | }
--------------------------------------------------------------------------------
/src/environments/environment.prod.ts:
--------------------------------------------------------------------------------
1 | export const environment = {
2 | production: true
3 | };
4 |
--------------------------------------------------------------------------------
/src/environments/environment.ts:
--------------------------------------------------------------------------------
1 | // The file contents for the current environment will overwrite these during build.
2 | // The build system defaults to the dev environment which uses `environment.ts`, but if you do
3 | // `ng build --env=prod` then `environment.prod.ts` will be used instead.
4 | // The list of which env maps to which file can be found in `.angular-cli.json`.
5 |
6 | export const environment = {
7 | production: false
8 | };
9 |
--------------------------------------------------------------------------------
/src/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | HTML5製のデザインツール Particle Develop - ICS
6 |
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 |
106 |
107 |
108 |
109 |
110 |
111 | Particle Develop
112 | LOADING...
113 |
114 |
115 |
116 |
117 |
118 |
119 |
120 |
132 |
133 |
134 |
--------------------------------------------------------------------------------
/src/main.ts:
--------------------------------------------------------------------------------
1 | import {enableProdMode} from '@angular/core';
2 | import {platformBrowserDynamic} from '@angular/platform-browser-dynamic';
3 | // BootstrapのJavaScript側の機能を読み込む
4 | import 'bootstrap';
5 |
6 | import {AppModule} from './app/app.module';
7 | import {environment} from './environments/environment';
8 |
9 | if (environment.production) {
10 | enableProdMode();
11 | }
12 |
13 | platformBrowserDynamic().bootstrapModule(AppModule);
14 |
15 | {
16 | // Webフォントをあとから読み込む
17 | const d = document;
18 | const element = d.createElement('link');
19 | element.setAttribute('rel', 'stylesheet');
20 | element.setAttribute('src', 'https://fonts.googleapis.com/earlyaccess/notosansjapanese.css');
21 | document.head.appendChild(element);
22 | }
23 |
24 | // サービスワーカーを起動する
25 | {
26 | if ('serviceWorker' in navigator) {
27 | navigator.serviceWorker.register('./service-worker.js');
28 | }
29 | }
30 |
31 | {
32 | document.documentElement.addEventListener('touchstart',
33 | (e) => {
34 | if (e.touches.length >= 2) {
35 | e.preventDefault();
36 | }
37 | }, {passive: false});
38 |
39 | /* ダブルタップによる拡大を禁止 */
40 | let t = 0;
41 | document.documentElement.addEventListener('touchend', (e) => {
42 | const now = new Date().getTime();
43 | if ((now - t) < 350) {
44 | e.preventDefault();
45 | }
46 | t = now;
47 | });
48 | }
49 |
--------------------------------------------------------------------------------
/src/polyfills.ts:
--------------------------------------------------------------------------------
1 | /**
2 | * This file includes polyfills needed by Angular and is loaded before the app.
3 | * You can add your own extra polyfills to this file.
4 | *
5 | * This file is divided into 2 sections:
6 | * 1. Browser polyfills. These are applied before loading ZoneJS and are sorted by browsers.
7 | * 2. Application imports. Files imported after ZoneJS that should be loaded before your main
8 | * file.
9 | *
10 | * The current setup is for so-called "evergreen" browsers; the last versions of browsers that
11 | * automatically update themselves. This includes Safari >= 10, Chrome >= 55 (including Opera),
12 | * Edge >= 13 on the desktop, and iOS 10 and Chrome on mobile.
13 | *
14 | * Learn more in https://angular.io/guide/browser-support
15 | */
16 |
17 | /***************************************************************************************************
18 | * BROWSER POLYFILLS
19 | */
20 |
21 |
22 | /** IE10 and IE11 requires the following for NgClass support on SVG elements */
23 | // import 'classlist.js'; // Run `npm install --save classlist.js`.
24 |
25 | /** IE10 and IE11 requires the following for the Reflect API. */
26 | import 'core-js/proposals/reflect-metadata';
27 |
28 | /**
29 | * Web Animations `@angular/platform-browser/animations`
30 | * Only required if AnimationBuilder is used within the application and using IE/Edge or Safari.
31 | * Standard animation support in Angular DOES NOT require any polyfills (as of Angular 6.0).
32 | **/
33 | // import 'web-animations-js'; // Run `npm install --save web-animations-js`.
34 |
35 | /**
36 | * By default, zone.js will patch all possible macroTask and DomEvents
37 | * user can disable parts of macroTask/DomEvents patch by setting following flags
38 | */
39 |
40 | // (window as any).__Zone_disable_requestAnimationFrame = true; // disable patch requestAnimationFrame
41 | // (window as any).__Zone_disable_on_property = true; // disable patch onProperty such as onclick
42 | // (window as any).__zone_symbol__BLACK_LISTED_EVENTS = ['scroll', 'mousemove']; // disable patch specified eventNames
43 |
44 | /*
45 | * in IE/Edge developer tools, the addEventListener will also be wrapped by zone.js
46 | * with the following flag, it will bypass `zone.js` patch for IE/Edge
47 | */
48 | // (window as any).__Zone_enable_cross_context_check = true;
49 |
50 | /***************************************************************************************************
51 | * Zone JS is required by default for Angular itself.
52 | */
53 | import 'zone.js/dist/zone'; // Included with Angular CLI.
54 |
55 |
56 |
57 | /***************************************************************************************************
58 | * APPLICATION IMPORTS
59 | */
60 |
--------------------------------------------------------------------------------
/src/pwa/manifest.json:
--------------------------------------------------------------------------------
1 | {
2 | "short_name": "Particle Develop",
3 | "name": "Particle Develop",
4 | "icons": [
5 | {
6 | "src": "./assets/images/ui/logo_512x512.png",
7 | "type": "image/png",
8 | "sizes": "512x512"
9 | }
10 | ],
11 | "start_url": "index.html?homescreen=1",
12 | "display": "standalone",
13 | "background_color": "#222222",
14 | "theme_color": "#222222"
15 | }
16 |
--------------------------------------------------------------------------------
/src/pwa/service-worker.js:
--------------------------------------------------------------------------------
1 | // -------------------------------
2 | // ワークボックスを使ってキャッシュ戦略を定義
3 | //
4 | //
5 | // ■キャッシュのレベルは次の指定が可能
6 | // 1. NetworkOnly: ネットワークからのみ返す
7 | // 2. NetworkFirst: ネットワークから優先して返すが、ネットワークから取得に失敗した場合はキャッシュから返す
8 | // 3. CacheFirst: キャッシュから優先して返すが、キャッシュになければネットワークから返す
9 | // 4. CacheOnly: キャッシュからのみ返す
10 | // 5. staleWhileRevalidate: まずキャッシュから優先して返すが、次回アクセス時に備えてバックグラウンドでネットワークから更新をフェッチしてキャッシュを更新しておく
11 | // -------------------------------
12 |
13 | // Googleのワークボックスを読み込む
14 | importScripts('https://storage.googleapis.com/workbox-cdn/releases/3.2.0/workbox-sw.js');
15 |
16 | workbox.setConfig({
17 | debug: true
18 | });
19 |
20 | workbox.routing.registerRoute(
21 | new RegExp('(.*)'),
22 | // ネットワーク通信を優先
23 | workbox.strategies.networkFirst()
24 | );
25 |
26 | // JSとCSSのキャッシュ戦略
27 | workbox.routing.registerRoute(
28 | new RegExp('^https://fonts.googleapis.com/(.*)'),
29 | // キャッシュを優先
30 | workbox.strategies.cacheFirst()
31 | );
32 |
33 |
--------------------------------------------------------------------------------
/src/scss/.csscomb.json:
--------------------------------------------------------------------------------
1 | {
2 | "always-semicolon": true,
3 | "block-indent": 2,
4 | "color-case": "lower",
5 | "color-shorthand": true,
6 | "element-case": "lower",
7 | "eof-newline": true,
8 | "leading-zero": false,
9 | "remove-empty-rulesets": true,
10 | "space-after-colon": 1,
11 | "space-after-combinator": 1,
12 | "space-before-selector-delimiter": 0,
13 | "space-between-declarations": "\n",
14 | "space-after-opening-brace": "\n",
15 | "space-before-closing-brace": "\n",
16 | "space-before-colon": 0,
17 | "space-before-combinator": 1,
18 | "space-before-opening-brace": 1,
19 | "strip-spaces": true,
20 | "unitless-zero": true,
21 | "vendor-prefix-align": true,
22 | "sort-order": [
23 | [
24 | "position",
25 | "top",
26 | "right",
27 | "bottom",
28 | "left",
29 | "z-index",
30 | "display",
31 | "float",
32 | "width",
33 | "min-width",
34 | "max-width",
35 | "height",
36 | "min-height",
37 | "max-height",
38 | "-webkit-box-sizing",
39 | "-moz-box-sizing",
40 | "box-sizing",
41 | "-webkit-appearance",
42 | "padding",
43 | "padding-top",
44 | "padding-right",
45 | "padding-bottom",
46 | "padding-left",
47 | "margin",
48 | "margin-top",
49 | "margin-right",
50 | "margin-bottom",
51 | "margin-left",
52 | "overflow",
53 | "overflow-x",
54 | "overflow-y",
55 | "-webkit-overflow-scrolling",
56 | "-ms-overflow-x",
57 | "-ms-overflow-y",
58 | "-ms-overflow-style",
59 | "clip",
60 | "clear",
61 | "font",
62 | "font-family",
63 | "font-size",
64 | "font-style",
65 | "font-weight",
66 | "font-variant",
67 | "font-size-adjust",
68 | "font-stretch",
69 | "font-effect",
70 | "font-emphasize",
71 | "font-emphasize-position",
72 | "font-emphasize-style",
73 | "font-smooth",
74 | "-webkit-hyphens",
75 | "-moz-hyphens",
76 | "hyphens",
77 | "line-height",
78 | "color",
79 | "text-align",
80 | "-webkit-text-align-last",
81 | "-moz-text-align-last",
82 | "-ms-text-align-last",
83 | "text-align-last",
84 | "text-emphasis",
85 | "text-emphasis-color",
86 | "text-emphasis-style",
87 | "text-emphasis-position",
88 | "text-decoration",
89 | "text-indent",
90 | "text-justify",
91 | "text-outline",
92 | "-ms-text-overflow",
93 | "text-overflow",
94 | "text-overflow-ellipsis",
95 | "text-overflow-mode",
96 | "text-shadow",
97 | "text-transform",
98 | "text-wrap",
99 | "-webkit-text-size-adjust",
100 | "-ms-text-size-adjust",
101 | "letter-spacing",
102 | "-ms-word-break",
103 | "word-break",
104 | "word-spacing",
105 | "-ms-word-wrap",
106 | "word-wrap",
107 | "-moz-tab-size",
108 | "-o-tab-size",
109 | "tab-size",
110 | "white-space",
111 | "vertical-align",
112 | "list-style",
113 | "list-style-position",
114 | "list-style-type",
115 | "list-style-image",
116 | "pointer-events",
117 | "-ms-touch-action",
118 | "touch-action",
119 | "cursor",
120 | "visibility",
121 | "zoom",
122 | "flex-direction",
123 | "flex-order",
124 | "flex-pack",
125 | "flex-align",
126 | "table-layout",
127 | "empty-cells",
128 | "caption-side",
129 | "border-spacing",
130 | "border-collapse",
131 | "content",
132 | "quotes",
133 | "counter-reset",
134 | "counter-increment",
135 | "resize",
136 | "-webkit-user-select",
137 | "-moz-user-select",
138 | "-ms-user-select",
139 | "-o-user-select",
140 | "user-select",
141 | "nav-index",
142 | "nav-up",
143 | "nav-right",
144 | "nav-down",
145 | "nav-left",
146 | "background",
147 | "background-color",
148 | "background-image",
149 | "-ms-filter:\\'progid:DXImageTransform.Microsoft.gradient",
150 | "filter:progid:DXImageTransform.Microsoft.gradient",
151 | "filter:progid:DXImageTransform.Microsoft.AlphaImageLoader",
152 | "filter",
153 | "background-repeat",
154 | "background-attachment",
155 | "background-position",
156 | "background-position-x",
157 | "background-position-y",
158 | "-webkit-background-clip",
159 | "-moz-background-clip",
160 | "background-clip",
161 | "background-origin",
162 | "-webkit-background-size",
163 | "-moz-background-size",
164 | "-o-background-size",
165 | "background-size",
166 | "border",
167 | "border-color",
168 | "border-style",
169 | "border-width",
170 | "border-top",
171 | "border-top-color",
172 | "border-top-style",
173 | "border-top-width",
174 | "border-right",
175 | "border-right-color",
176 | "border-right-style",
177 | "border-right-width",
178 | "border-bottom",
179 | "border-bottom-color",
180 | "border-bottom-style",
181 | "border-bottom-width",
182 | "border-left",
183 | "border-left-color",
184 | "border-left-style",
185 | "border-left-width",
186 | "border-radius",
187 | "border-top-left-radius",
188 | "border-top-right-radius",
189 | "border-bottom-right-radius",
190 | "border-bottom-left-radius",
191 | "-webkit-border-image",
192 | "-moz-border-image",
193 | "-o-border-image",
194 | "border-image",
195 | "-webkit-border-image-source",
196 | "-moz-border-image-source",
197 | "-o-border-image-source",
198 | "border-image-source",
199 | "-webkit-border-image-slice",
200 | "-moz-border-image-slice",
201 | "-o-border-image-slice",
202 | "border-image-slice",
203 | "-webkit-border-image-width",
204 | "-moz-border-image-width",
205 | "-o-border-image-width",
206 | "border-image-width",
207 | "-webkit-border-image-outset",
208 | "-moz-border-image-outset",
209 | "-o-border-image-outset",
210 | "border-image-outset",
211 | "-webkit-border-image-repeat",
212 | "-moz-border-image-repeat",
213 | "-o-border-image-repeat",
214 | "border-image-repeat",
215 | "outline",
216 | "outline-width",
217 | "outline-style",
218 | "outline-color",
219 | "outline-offset",
220 | "-webkit-box-shadow",
221 | "-moz-box-shadow",
222 | "box-shadow",
223 | "filter:progid:DXImageTransform.Microsoft.Alpha(Opacity",
224 | "-ms-filter:\\'progid:DXImageTransform.Microsoft.Alpha",
225 | "opacity",
226 | "-ms-interpolation-mode",
227 | "-webkit-transition",
228 | "-moz-transition",
229 | "-ms-transition",
230 | "-o-transition",
231 | "transition",
232 | "-webkit-transition-delay",
233 | "-moz-transition-delay",
234 | "-ms-transition-delay",
235 | "-o-transition-delay",
236 | "transition-delay",
237 | "-webkit-transition-timing-function",
238 | "-moz-transition-timing-function",
239 | "-ms-transition-timing-function",
240 | "-o-transition-timing-function",
241 | "transition-timing-function",
242 | "-webkit-transition-duration",
243 | "-moz-transition-duration",
244 | "-ms-transition-duration",
245 | "-o-transition-duration",
246 | "transition-duration",
247 | "-webkit-transition-property",
248 | "-moz-transition-property",
249 | "-ms-transition-property",
250 | "-o-transition-property",
251 | "transition-property",
252 | "-webkit-transform",
253 | "-moz-transform",
254 | "-ms-transform",
255 | "-o-transform",
256 | "transform",
257 | "-webkit-transform-origin",
258 | "-moz-transform-origin",
259 | "-ms-transform-origin",
260 | "-o-transform-origin",
261 | "transform-origin",
262 | "-webkit-animation",
263 | "-moz-animation",
264 | "-ms-animation",
265 | "-o-animation",
266 | "animation",
267 | "-webkit-animation-name",
268 | "-moz-animation-name",
269 | "-ms-animation-name",
270 | "-o-animation-name",
271 | "animation-name",
272 | "-webkit-animation-duration",
273 | "-moz-animation-duration",
274 | "-ms-animation-duration",
275 | "-o-animation-duration",
276 | "animation-duration",
277 | "-webkit-animation-play-state",
278 | "-moz-animation-play-state",
279 | "-ms-animation-play-state",
280 | "-o-animation-play-state",
281 | "animation-play-state",
282 | "-webkit-animation-timing-function",
283 | "-moz-animation-timing-function",
284 | "-ms-animation-timing-function",
285 | "-o-animation-timing-function",
286 | "animation-timing-function",
287 | "-webkit-animation-delay",
288 | "-moz-animation-delay",
289 | "-ms-animation-delay",
290 | "-o-animation-delay",
291 | "animation-delay",
292 | "-webkit-animation-iteration-count",
293 | "-moz-animation-iteration-count",
294 | "-ms-animation-iteration-count",
295 | "-o-animation-iteration-count",
296 | "animation-iteration-count",
297 | "-webkit-animation-direction",
298 | "-moz-animation-direction",
299 | "-ms-animation-direction",
300 | "-o-animation-direction",
301 | "animation-direction"
302 | ]
303 | ]
304 | }
305 |
--------------------------------------------------------------------------------
/src/scss/.scss-lint.yml:
--------------------------------------------------------------------------------
1 | scss_files: "scss/*.scss"
2 |
3 | linters:
4 | BangFormat:
5 | enabled: true
6 | space_before_bang: true
7 | space_after_bang: false
8 |
9 | BorderZero:
10 | enabled: true
11 |
12 | ColorKeyword:
13 | enabled: true
14 |
15 | ColorVariable:
16 | enabled: false
17 |
18 | Comment:
19 | enabled: true
20 | exclude: ['_normalize.scss', 'bootstrap.scss']
21 |
22 | DebugStatement:
23 | enabled: true
24 |
25 | DeclarationOrder:
26 | enabled: false
27 |
28 | DuplicateProperty:
29 | enabled: true
30 | exclude: ['mixins/_tab-focus.scss', '_reboot.scss']
31 |
32 | ElsePlacement:
33 | enabled: true
34 | style: same_line # or 'new_line'
35 |
36 | EmptyLineBetweenBlocks:
37 | enabled: false
38 | ignore_single_line_blocks: true
39 |
40 | EmptyRule:
41 | enabled: true
42 |
43 | FinalNewline:
44 | enabled: true
45 | present: true
46 |
47 | HexLength:
48 | enabled: true
49 | style: short # or 'long'
50 |
51 | HexNotation:
52 | enabled: true
53 | style: lowercase # or 'uppercase'
54 |
55 | HexValidation:
56 | enabled: true
57 |
58 | IdSelector:
59 | enabled: true
60 |
61 | ImportantRule:
62 | enabled: false
63 |
64 | ImportPath:
65 | enabled: true
66 | leading_underscore: false
67 | filename_extension: false
68 |
69 | Indentation:
70 | enabled: true
71 | character: space # or 'tab'
72 | width: 2
73 |
74 | LeadingZero:
75 | enabled: false
76 | style: exclude_zero # or 'include_zero'
77 |
78 | MergeableSelector:
79 | enabled: false
80 | force_nesting: true
81 |
82 | NameFormat:
83 | enabled: true
84 | allow_leading_underscore: true
85 | convention: hyphenated_lowercase # or 'BEM', or a regex pattern
86 |
87 | NestingDepth:
88 | enabled: false
89 |
90 | PlaceholderInExtend:
91 | enabled: false
92 |
93 | PropertySortOrder:
94 | enabled: true
95 | ignore_unspecified: false
96 | severity: warning
97 | exclude: ['_normalize.scss']
98 | order: [
99 | "position",
100 | "top",
101 | "right",
102 | "bottom",
103 | "left",
104 | "z-index",
105 | "-webkit-box-sizing",
106 | "-moz-box-sizing",
107 | "box-sizing",
108 | "display",
109 | "float",
110 | "width",
111 | "min-width",
112 | "max-width",
113 | "height",
114 | "min-height",
115 | "max-height",
116 | "flex",
117 | "flex-direction",
118 | "flex-flow",
119 | "flex-order",
120 | "flex-pack",
121 | "flex-align",
122 | "padding",
123 | "padding-top",
124 | "padding-right",
125 | "padding-bottom",
126 | "padding-left",
127 | "margin",
128 | "margin-top",
129 | "margin-right",
130 | "margin-bottom",
131 | "margin-left",
132 | "overflow",
133 | "overflow-x",
134 | "overflow-y",
135 | "-webkit-overflow-scrolling",
136 | "-ms-overflow-x",
137 | "-ms-overflow-y",
138 | "-ms-overflow-style",
139 | "clip",
140 | "clear",
141 | "font",
142 | "font-family",
143 | "font-size",
144 | "font-style",
145 | "font-weight",
146 | "font-variant",
147 | "font-size-adjust",
148 | "font-stretch",
149 | "font-effect",
150 | "font-emphasize",
151 | "font-emphasize-position",
152 | "font-emphasize-style",
153 | "font-smooth",
154 | "-webkit-hyphens",
155 | "-moz-hyphens",
156 | "hyphens",
157 | "line-height",
158 | "color",
159 | "text-align",
160 | "-webkit-text-align-last",
161 | "-moz-text-align-last",
162 | "-ms-text-align-last",
163 | "text-align-last",
164 | "text-emphasis",
165 | "text-emphasis-color",
166 | "text-emphasis-style",
167 | "text-emphasis-position",
168 | "text-decoration",
169 | "text-indent",
170 | "text-justify",
171 | "text-outline",
172 | "-ms-text-overflow",
173 | "text-overflow",
174 | "text-overflow-ellipsis",
175 | "text-overflow-mode",
176 | "text-shadow",
177 | "text-transform",
178 | "text-wrap",
179 | "-webkit-text-size-adjust",
180 | "-ms-text-size-adjust",
181 | "letter-spacing",
182 | "-ms-word-break",
183 | "word-break",
184 | "word-spacing",
185 | "-ms-word-wrap",
186 | "word-wrap",
187 | "-moz-tab-size",
188 | "-o-tab-size",
189 | "tab-size",
190 | "white-space",
191 | "vertical-align",
192 | "list-style",
193 | "list-style-position",
194 | "list-style-type",
195 | "list-style-image",
196 | "pointer-events",
197 | "-ms-touch-action",
198 | "touch-action",
199 | "cursor",
200 | "visibility",
201 | "zoom",
202 | "table-layout",
203 | "empty-cells",
204 | "caption-side",
205 | "border-spacing",
206 | "border-collapse",
207 | "content",
208 | "quotes",
209 | "counter-reset",
210 | "counter-increment",
211 | "resize",
212 | "-webkit-user-select",
213 | "-moz-user-select",
214 | "-ms-user-select",
215 | "-o-user-select",
216 | "user-select",
217 | "nav-index",
218 | "nav-up",
219 | "nav-right",
220 | "nav-down",
221 | "nav-left",
222 | "background",
223 | "background-color",
224 | "background-image",
225 | "-ms-filter:\\'progid:DXImageTransform.Microsoft.gradient",
226 | "filter:progid:DXImageTransform.Microsoft.gradient",
227 | "filter:progid:DXImageTransform.Microsoft.AlphaImageLoader",
228 | "filter",
229 | "background-repeat",
230 | "background-attachment",
231 | "background-position",
232 | "background-position-x",
233 | "background-position-y",
234 | "-webkit-background-clip",
235 | "-moz-background-clip",
236 | "background-clip",
237 | "background-origin",
238 | "-webkit-background-size",
239 | "-moz-background-size",
240 | "-o-background-size",
241 | "background-size",
242 | "border",
243 | "border-color",
244 | "border-style",
245 | "border-width",
246 | "border-top",
247 | "border-top-color",
248 | "border-top-style",
249 | "border-top-width",
250 | "border-right",
251 | "border-right-color",
252 | "border-right-style",
253 | "border-right-width",
254 | "border-bottom",
255 | "border-bottom-color",
256 | "border-bottom-style",
257 | "border-bottom-width",
258 | "border-left",
259 | "border-left-color",
260 | "border-left-style",
261 | "border-left-width",
262 | "border-radius",
263 | "border-top-left-radius",
264 | "border-top-right-radius",
265 | "border-bottom-right-radius",
266 | "border-bottom-left-radius",
267 | "-webkit-border-image",
268 | "-moz-border-image",
269 | "-o-border-image",
270 | "border-image",
271 | "-webkit-border-image-source",
272 | "-moz-border-image-source",
273 | "-o-border-image-source",
274 | "border-image-source",
275 | "-webkit-border-image-slice",
276 | "-moz-border-image-slice",
277 | "-o-border-image-slice",
278 | "border-image-slice",
279 | "-webkit-border-image-width",
280 | "-moz-border-image-width",
281 | "-o-border-image-width",
282 | "border-image-width",
283 | "-webkit-border-image-outset",
284 | "-moz-border-image-outset",
285 | "-o-border-image-outset",
286 | "border-image-outset",
287 | "-webkit-border-image-repeat",
288 | "-moz-border-image-repeat",
289 | "-o-border-image-repeat",
290 | "border-image-repeat",
291 | "outline",
292 | "outline-width",
293 | "outline-style",
294 | "outline-color",
295 | "outline-offset",
296 | "-webkit-box-shadow",
297 | "-moz-box-shadow",
298 | "box-shadow",
299 | "filter:progid:DXImageTransform.Microsoft.Alpha(Opacity",
300 | "-ms-filter:\\'progid:DXImageTransform.Microsoft.Alpha",
301 | "opacity",
302 | "-ms-interpolation-mode",
303 | "-webkit-transition",
304 | "-moz-transition",
305 | "-ms-transition",
306 | "-o-transition",
307 | "transition",
308 | "-webkit-transition-delay",
309 | "-moz-transition-delay",
310 | "-ms-transition-delay",
311 | "-o-transition-delay",
312 | "transition-delay",
313 | "-webkit-transition-timing-function",
314 | "-moz-transition-timing-function",
315 | "-ms-transition-timing-function",
316 | "-o-transition-timing-function",
317 | "transition-timing-function",
318 | "-webkit-transition-duration",
319 | "-moz-transition-duration",
320 | "-ms-transition-duration",
321 | "-o-transition-duration",
322 | "transition-duration",
323 | "-webkit-transition-property",
324 | "-moz-transition-property",
325 | "-ms-transition-property",
326 | "-o-transition-property",
327 | "transition-property",
328 | "-webkit-transform",
329 | "-moz-transform",
330 | "-ms-transform",
331 | "-o-transform",
332 | "transform",
333 | "-webkit-transform-origin",
334 | "-moz-transform-origin",
335 | "-ms-transform-origin",
336 | "-o-transform-origin",
337 | "transform-origin",
338 | "-webkit-animation",
339 | "-moz-animation",
340 | "-ms-animation",
341 | "-o-animation",
342 | "animation",
343 | "-webkit-animation-name",
344 | "-moz-animation-name",
345 | "-ms-animation-name",
346 | "-o-animation-name",
347 | "animation-name",
348 | "-webkit-animation-duration",
349 | "-moz-animation-duration",
350 | "-ms-animation-duration",
351 | "-o-animation-duration",
352 | "animation-duration",
353 | "-webkit-animation-play-state",
354 | "-moz-animation-play-state",
355 | "-ms-animation-play-state",
356 | "-o-animation-play-state",
357 | "animation-play-state",
358 | "-webkit-animation-timing-function",
359 | "-moz-animation-timing-function",
360 | "-ms-animation-timing-function",
361 | "-o-animation-timing-function",
362 | "animation-timing-function",
363 | "-webkit-animation-delay",
364 | "-moz-animation-delay",
365 | "-ms-animation-delay",
366 | "-o-animation-delay",
367 | "animation-delay",
368 | "-webkit-animation-iteration-count",
369 | "-moz-animation-iteration-count",
370 | "-ms-animation-iteration-count",
371 | "-o-animation-iteration-count",
372 | "animation-iteration-count",
373 | "-webkit-animation-direction",
374 | "-moz-animation-direction",
375 | "-ms-animation-direction",
376 | "-o-animation-direction",
377 | "animation-direction"
378 | ]
379 |
380 | PropertySpelling:
381 | enabled: true
382 | extra_properties: []
383 |
384 | PseudoElement:
385 | enabled: true
386 |
387 | QualifyingElement:
388 | enabled: false
389 | allow_element_with_attribute: false
390 | allow_element_with_class: false
391 | allow_element_with_id: false
392 |
393 | SelectorDepth:
394 | enabled: false
395 |
396 | SelectorFormat:
397 | enabled: true
398 | convention: hyphenated_lowercase # or 'BEM', or 'snake_case', or 'camel_case', or a regex pattern
399 |
400 | Shorthand:
401 | enabled: true
402 |
403 | SingleLinePerProperty:
404 | enabled: true
405 | allow_single_line_rule_sets: true
406 |
407 | SingleLinePerSelector:
408 | enabled: false
409 |
410 | SpaceAfterComma:
411 | enabled: false
412 |
413 | SpaceAfterPropertyColon:
414 | enabled: true
415 | style: at_least_one_space # or 'no_space', or 'at_least_one_space', or 'aligned'
416 |
417 | SpaceAfterPropertyName:
418 | enabled: true
419 |
420 | SpaceBeforeBrace:
421 | enabled: true
422 | style: space
423 | allow_single_line_padding: true
424 |
425 | SpaceBetweenParens:
426 | enabled: true
427 | spaces: 0
428 |
429 | StringQuotes:
430 | enabled: true
431 | style: double_quotes
432 |
433 | TrailingSemicolon:
434 | enabled: true
435 |
436 | TrailingZero:
437 | enabled: false
438 |
439 | UnnecessaryMantissa:
440 | enabled: true
441 |
442 | UnnecessaryParentReference:
443 | enabled: true
444 |
445 | UrlFormat:
446 | enabled: true
447 |
448 | UrlQuotes:
449 | enabled: true
450 |
451 | VendorPrefixes:
452 | enabled: true
453 | identifier_list: base
454 | include: []
455 | exclude: ['_normalize.scss']
456 |
457 | ZeroUnit:
458 | enabled: true
459 |
460 | Compass::*:
461 | enabled: false
462 |
--------------------------------------------------------------------------------
/src/scss/ics/particledevelop.scss:
--------------------------------------------------------------------------------
1 | html, body {
2 | height: 100%;
3 | }
4 |
5 | body {
6 | overflow: hidden;
7 | padding: 0;
8 |
9 | /*スクロールバー全体*/
10 | ::-webkit-scrollbar {
11 | width: 7px;
12 | }
13 |
14 | /*スクロールバーの軌道*/
15 | ::-webkit-scrollbar-track {
16 | border-radius: 0;
17 | background-color: rgba(33, 33, 33, 0.25);
18 | }
19 |
20 | /*スクロールバーの動く部分*/
21 | ::-webkit-scrollbar-thumb {
22 | background-color: rgba(0, 0, 0, 0.5);
23 | border-radius: 0;
24 | }
25 | ::-webkit-scrollbar-corner {
26 | background-color: rgba(0, 0, 0, .5);
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/src/styles.scss:
--------------------------------------------------------------------------------
1 | /* You can add global styles to this file, and also import other style files */
2 |
3 | html{
4 | font-size: 14px;
5 | }
6 |
7 | @import "../node_modules/bootstrap/scss/functions.scss";
8 | @import "scss/ics/variables.scss";
9 |
10 | /* Bootstrap を読み込む */
11 | @import "../node_modules/bootstrap/scss/bootstrap.scss";
12 |
13 |
14 | @import "../node_modules/font-awesome/css/font-awesome.min.css";
15 |
16 | @import "scss/ics/particledevelop.scss";
17 |
18 | @import "embeds/topcoat/topcoat-desktop-dark.custom.css";
19 |
--------------------------------------------------------------------------------
/src/tsconfig.app.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "../tsconfig.base.json",
3 | "compilerOptions": {
4 | "outDir": "../out-tsc/app",
5 | "baseUrl": "",
6 | "types": []
7 | },
8 | "files": [
9 | "main.ts",
10 | "polyfills.ts"
11 | ],
12 | "include": [
13 | "**/*.d.ts"
14 | ]
15 | }
16 |
--------------------------------------------------------------------------------
/src/typings.d.ts:
--------------------------------------------------------------------------------
1 | ///
2 |
3 | /* SystemJS module definition */
4 | declare var module:NodeModule;
5 | interface NodeModule {
6 | id:string;
7 | }
8 |
--------------------------------------------------------------------------------
/tsconfig.base.json:
--------------------------------------------------------------------------------
1 | {
2 | "compileOnSave": false,
3 | "compilerOptions": {
4 | // いつか true に設定したい
5 | "strict": false,
6 | "downlevelIteration": true,
7 | "importHelpers": true,
8 | "module": "es2020",
9 | "outDir": "./dist/out-tsc",
10 | "baseUrl": "src",
11 | "sourceMap": true,
12 | "declaration": false,
13 | "moduleResolution": "node",
14 | "emitDecoratorMetadata": true,
15 | "experimentalDecorators": true,
16 | "target": "es5",
17 | "lib": [
18 | "es2019",
19 | "dom"
20 | ]
21 | },
22 | "angularCompilerOptions": {
23 | }
24 | }
25 |
--------------------------------------------------------------------------------
/tsconfig.json:
--------------------------------------------------------------------------------
1 | /*
2 | This is a "Solution Style" tsconfig.json file, and is used by editors and TypeScript’s language server to improve development experience.
3 | It is not intended to be used to perform a compilation.
4 |
5 | To learn more about this file see: https://angular.io/config/solution-tsconfig.
6 | */
7 | {
8 | "files": [],
9 | "references": [
10 | {
11 | "path": "./src/tsconfig.app.json"
12 | }
13 | ]
14 | }
--------------------------------------------------------------------------------
/tslint.json:
--------------------------------------------------------------------------------
1 | {
2 | "rulesDirectory": [
3 | "node_modules/codelyzer"
4 | ],
5 | "rules": {
6 | "arrow-return-shorthand": true,
7 | "callable-types": true,
8 | "class-name": true,
9 | "comment-format": [
10 | true,
11 | "check-space"
12 | ],
13 | "curly": true,
14 | "deprecation": {
15 | "severity": "warn"
16 | },
17 | "eofline": true,
18 | "forin": true,
19 | "import-blacklist": [
20 | true,
21 | "rxjs/Rx"
22 | ],
23 | "import-spacing": true,
24 | "indent": [
25 | true,
26 | "spaces"
27 | ],
28 | "interface-over-type-literal": true,
29 | "label-position": true,
30 | "max-line-length": [
31 | true,
32 | 140
33 | ],
34 | "member-access": false,
35 | "member-ordering": [
36 | true,
37 | {
38 | "order": [
39 | "static-field",
40 | "instance-field",
41 | "static-method",
42 | "instance-method"
43 | ]
44 | }
45 | ],
46 | "no-arg": true,
47 | "no-bitwise": true,
48 | "no-console": [
49 | true,
50 | "debug",
51 | "info",
52 | "time",
53 | "timeEnd",
54 | "trace"
55 | ],
56 | "no-construct": true,
57 | "no-debugger": true,
58 | "no-duplicate-super": true,
59 | "no-empty": false,
60 | "no-empty-interface": true,
61 | "no-eval": true,
62 | "no-inferrable-types": [
63 | true,
64 | "ignore-params"
65 | ],
66 | "no-misused-new": true,
67 | "no-non-null-assertion": true,
68 | "no-shadowed-variable": true,
69 | "no-string-literal": false,
70 | "no-string-throw": true,
71 | "no-switch-case-fall-through": true,
72 | "no-trailing-whitespace": true,
73 | "no-unnecessary-initializer": true,
74 | "no-unused-expression": true,
75 | "no-var-keyword": true,
76 | "object-literal-sort-keys": false,
77 | "one-line": [
78 | true,
79 | "check-open-brace",
80 | "check-catch",
81 | "check-else",
82 | "check-whitespace"
83 | ],
84 | "prefer-const": true,
85 | "quotemark": [
86 | true,
87 | "single"
88 | ],
89 | "radix": true,
90 | "semicolon": [
91 | true,
92 | "always"
93 | ],
94 | "triple-equals": [
95 | true,
96 | "allow-null-check"
97 | ],
98 | "typedef-whitespace": [
99 | true,
100 | {
101 | "call-signature": "nospace",
102 | "index-signature": "nospace",
103 | "parameter": "nospace",
104 | "property-declaration": "nospace",
105 | "variable-declaration": "nospace"
106 | }
107 | ],
108 | "unified-signatures": true,
109 | "variable-name": false,
110 | "whitespace": [
111 | true,
112 | "check-branch",
113 | "check-decl",
114 | "check-operator",
115 | "check-separator",
116 | "check-type"
117 | ],
118 | "no-output-on-prefix": true,
119 | "no-inputs-metadata-property": true,
120 | "no-outputs-metadata-property": true,
121 | "no-host-metadata-property": true,
122 | "no-input-rename": true,
123 | "no-output-rename": true,
124 | "use-lifecycle-interface": true,
125 | "use-pipe-transform-interface": true,
126 | "component-class-suffix": true,
127 | "directive-class-suffix": true
128 | }
129 | }
130 |
--------------------------------------------------------------------------------