Commit a06e52d7 authored by 神楽坂玲奈's avatar 神楽坂玲奈

nya

parent 26800575
{
"name": "mycard-mobile",
"version": "1.0.4",
"version": "1.0.6",
"lockfileVersion": 1,
"requires": true,
"dependencies": {
......@@ -494,6 +494,11 @@
"integrity": "sha1-x57Zf380y48robyXkLzDZkdLS3k=",
"dev": true
},
"atoa": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/atoa/-/atoa-1.0.0.tgz",
"integrity": "sha1-DMDpGkgOc4+SPrwQNnZHF3mzSkk="
},
"autoprefixer": {
"version": "6.7.7",
"resolved": "https://registry.npmjs.org/autoprefixer/-/autoprefixer-6.7.7.tgz",
......@@ -1219,6 +1224,15 @@
"integrity": "sha1-t9ETrueo3Se9IRM8TcJSnfFyHu0=",
"dev": true
},
"contra": {
"version": "1.9.4",
"resolved": "https://registry.npmjs.org/contra/-/contra-1.9.4.tgz",
"integrity": "sha1-9TveQtfltZhcrk2ZqNYQUm3o8o0=",
"requires": {
"atoa": "1.0.0",
"ticky": "1.0.1"
}
},
"convert-source-map": {
"version": "1.5.0",
"resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.5.0.tgz",
......@@ -1327,6 +1341,14 @@
"which": "1.2.14"
}
},
"crossvent": {
"version": "1.5.4",
"resolved": "https://registry.npmjs.org/crossvent/-/crossvent-1.5.4.tgz",
"integrity": "sha1-2ixPj0DJR4JRe/K+7BBEFIGUq5I=",
"requires": {
"custom-event": "1.0.0"
}
},
"cryptiles": {
"version": "2.0.5",
"resolved": "https://registry.npmjs.org/cryptiles/-/cryptiles-2.0.5.tgz",
......@@ -1492,6 +1514,11 @@
"array-find-index": "1.0.2"
}
},
"custom-event": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/custom-event/-/custom-event-1.0.0.tgz",
"integrity": "sha1-LkYovhncSyFLXAJjDFlx6BFhgGI="
},
"dashdash": {
"version": "1.14.1",
"resolved": "https://registry.npmjs.org/dashdash/-/dashdash-1.14.1.tgz",
......@@ -1530,6 +1557,11 @@
"integrity": "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA=",
"dev": true
},
"deepmerge": {
"version": "1.5.0",
"resolved": "https://registry.npmjs.org/deepmerge/-/deepmerge-1.5.0.tgz",
"integrity": "sha512-Hm4+NyDQGgH3oYhKqR0gd99veBBZpnEUNoEfFl+3PRkQL+LKGJEBgqimeofAWzUn6aBzcaYPJrRigto/WfDzTg=="
},
"defined": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/defined/-/defined-1.0.0.tgz",
......@@ -1708,6 +1740,15 @@
"domelementtype": "1.3.0"
}
},
"dragula": {
"version": "3.7.2",
"resolved": "https://registry.npmjs.org/dragula/-/dragula-3.7.2.tgz",
"integrity": "sha1-SjXJ05gf+sGpScKcpyhQWOhzk84=",
"requires": {
"contra": "1.9.4",
"crossvent": "1.5.4"
}
},
"ecc-jsbn": {
"version": "0.1.1",
"resolved": "https://registry.npmjs.org/ecc-jsbn/-/ecc-jsbn-0.1.1.tgz",
......@@ -1772,6 +1813,14 @@
"integrity": "sha1-eePVhlU0aQn+bw9Fpd5oEDspTSA=",
"dev": true
},
"encoding": {
"version": "0.1.12",
"resolved": "https://registry.npmjs.org/encoding/-/encoding-0.1.12.tgz",
"integrity": "sha1-U4tm8+5izRq1HsMjgp0flIDHS+s=",
"requires": {
"iconv-lite": "0.4.18"
}
},
"enhanced-resolve": {
"version": "3.3.0",
"resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-3.3.0.tgz",
......@@ -3627,8 +3676,7 @@
"iconv-lite": {
"version": "0.4.18",
"resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.18.tgz",
"integrity": "sha512-sr1ZQph3UwHTR0XftSbK85OvBbxe/abLGzEnPENCQwmHf7sck8Oyu4ob3LgBxWWxRoM+QszeUyl7jbqapu2TqA==",
"dev": true
"integrity": "sha512-sr1ZQph3UwHTR0XftSbK85OvBbxe/abLGzEnPENCQwmHf7sck8Oyu4ob3LgBxWWxRoM+QszeUyl7jbqapu2TqA=="
},
"icss-replace-symbols": {
"version": "1.1.0",
......@@ -4007,6 +4055,11 @@
"integrity": "sha1-eaKp7OfwlugPNtKy87wWwf9L8/o=",
"dev": true
},
"is-stream": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/is-stream/-/is-stream-1.1.0.tgz",
"integrity": "sha1-EtSj3U5o4Lec6428hBc66A2RykQ="
},
"is-svg": {
"version": "2.1.0",
"resolved": "https://registry.npmjs.org/is-svg/-/is-svg-2.1.0.tgz",
......@@ -4665,6 +4718,14 @@
"integrity": "sha1-KzJxhOiZIQEXeyhWP7XnECrNDKk=",
"dev": true
},
"ng2-dragula": {
"version": "1.5.0",
"resolved": "https://registry.npmjs.org/ng2-dragula/-/ng2-dragula-1.5.0.tgz",
"integrity": "sha512-uSVq66Rv+ZhDLBGYCGZ7mTaseP7rvYJOijiQZlzfy8dxL614Sw7rhtnLqvK8nqa3tI/wVv8CEGZaZkMnWJokwQ==",
"requires": {
"dragula": "3.7.2"
}
},
"no-case": {
"version": "2.3.1",
"resolved": "https://registry.npmjs.org/no-case/-/no-case-2.3.1.tgz",
......@@ -4674,6 +4735,15 @@
"lower-case": "1.1.4"
}
},
"node-fetch": {
"version": "1.7.1",
"resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-1.7.1.tgz",
"integrity": "sha512-j8XsFGCLw79vWXkZtMSmmLaOk9z5SQ9bV/tkbZVCqvgwzrjAGq66igobLofHtF63NvMTp2WjytpsNTGKa+XRIQ==",
"requires": {
"encoding": "0.1.12",
"is-stream": "1.1.0"
}
},
"node-gyp": {
"version": "3.6.2",
"resolved": "https://registry.npmjs.org/node-gyp/-/node-gyp-3.6.2.tgz",
......@@ -6311,6 +6381,14 @@
"symbol-observable": "1.0.4"
}
},
"rxjs-to-async-iterator": {
"version": "2.1.3",
"resolved": "https://registry.npmjs.org/rxjs-to-async-iterator/-/rxjs-to-async-iterator-2.1.3.tgz",
"integrity": "sha1-ILy/ycM6Sc6dRJUZcGlz3R25isM=",
"requires": {
"rxjs": "5.4.2"
}
},
"safe-buffer": {
"version": "5.1.1",
"resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.1.tgz",
......@@ -6354,8 +6432,7 @@
"sax": {
"version": "1.2.4",
"resolved": "https://registry.npmjs.org/sax/-/sax-1.2.4.tgz",
"integrity": "sha512-NqVDv9TpANUjFm0N8uM5GxL36UgKi9/atZw+x7YFnQ8ckwFGKrl4xX4yWtrey3UJm5nP1kUbnYgLopqWNSRhWw==",
"dev": true
"integrity": "sha512-NqVDv9TpANUjFm0N8uM5GxL36UgKi9/atZw+x7YFnQ8ckwFGKrl4xX4yWtrey3UJm5nP1kUbnYgLopqWNSRhWw=="
},
"schema-utils": {
"version": "0.3.0",
......@@ -7005,6 +7082,11 @@
"integrity": "sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU=",
"dev": true
},
"ticky": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/ticky/-/ticky-1.0.1.tgz",
"integrity": "sha1-t8+nHnaPHJAAxJe5FRswlHxQ5G0="
},
"timers-browserify": {
"version": "2.0.2",
"resolved": "https://registry.npmjs.org/timers-browserify/-/timers-browserify-2.0.2.tgz",
......@@ -7393,6 +7475,16 @@
"resolved": "https://registry.npmjs.org/web-animations-js/-/web-animations-js-2.3.1.tgz",
"integrity": "sha1-Om2bwVGWN3qQ+OKAP6UmIWWwRRA="
},
"webdav": {
"version": "1.0.0-rc1",
"resolved": "https://registry.npmjs.org/webdav/-/webdav-1.0.0-rc1.tgz",
"integrity": "sha1-UT6nI8EdnqnqGw4ND0TzxoXIS1U=",
"requires": {
"deepmerge": "1.5.0",
"node-fetch": "1.7.1",
"xml2js": "0.4.17"
}
},
"webpack": {
"version": "2.4.1",
"resolved": "https://registry.npmjs.org/webpack/-/webpack-2.4.1.tgz",
......@@ -7856,6 +7948,23 @@
"integrity": "sha1-ZGV4SKIP/F31g6Qq2KJ3tFErvE0=",
"dev": true
},
"xml2js": {
"version": "0.4.17",
"resolved": "https://registry.npmjs.org/xml2js/-/xml2js-0.4.17.tgz",
"integrity": "sha1-F76T6q4/O3eTWceVtBlwWogX6Gg=",
"requires": {
"sax": "1.2.4",
"xmlbuilder": "4.2.1"
}
},
"xmlbuilder": {
"version": "4.2.1",
"resolved": "https://registry.npmjs.org/xmlbuilder/-/xmlbuilder-4.2.1.tgz",
"integrity": "sha1-qlijBBoGb5DqoWwvU4n/GfP0YaU=",
"requires": {
"lodash": "4.17.4"
}
},
"xmldom": {
"version": "0.1.27",
"resolved": "https://registry.npmjs.org/xmldom/-/xmldom-0.1.27.tgz",
......
......@@ -8,6 +8,7 @@ import { NewRoomComponent } from './new-room/new-room.component';
import { RoomListComponent } from './room-list/room-list.component';
import { WindbotComponent } from './windbot/windbot.component';
import { WatchComponent } from './watch/watch.component';
import { DecksComponent } from './decks/decks.component';
const routes: Routes = [
{
......@@ -20,6 +21,7 @@ const routes: Routes = [
{ path: 'ygopro/lobby', component: LobbyComponent },
{ path: 'ygopro/windbot', component: WindbotComponent },
{ path: 'ygopro/watch', component: WatchComponent },
{ path: 'ygopro/decks', component: DecksComponent },
]
},
];
......
......@@ -35,6 +35,9 @@ import { ToolbarComponent } from './toolbar/toolbar.component';
import { WatchComponent } from './watch/watch.component';
import { WindbotComponent } from './windbot/windbot.component';
import { YGOProService } from './ygopro.service';
import { DecksComponent } from './decks/decks.component';
import { DragulaModule } from 'ng2-dragula';
import { SaveService } from './save.service';
@NgModule({
declarations: [
......@@ -47,6 +50,7 @@ import { YGOProService } from './ygopro.service';
WatchComponent,
ToolbarComponent,
ResultDialog,
DecksComponent,
],
imports: [
BrowserModule,
......@@ -72,9 +76,10 @@ import { YGOProService } from './ygopro.service';
ReactiveFormsModule,
JsonpModule,
MdMenuModule,
MdProgressSpinnerModule
MdProgressSpinnerModule,
DragulaModule
],
providers: [YGOProService],
providers: [YGOProService, SaveService],
bootstrap: [AppComponent],
entryComponents: [MatchDialog, ResultDialog],
})
......
......@@ -8,6 +8,7 @@ import { LoginService } from '../login.service';
import { MatchDialog } from '../match/match.component';
import { routerTransition2 } from '../router.animations';
import { YGOProService } from '../ygopro.service';
import { SaveService } from '../save.service';
@Component({
selector: 'app-lobby',
templateUrl: 'lobby.component.html',
......@@ -29,7 +30,7 @@ export class LobbyComponent {
arena_url: string;
constructor(public login: LoginService, public ygopro: YGOProService, public dialog: MdDialog, private http: Http, private jsonp: Jsonp, private route: ActivatedRoute) {
constructor(public login: LoginService, public ygopro: YGOProService, public dialog: MdDialog, private http: Http, private jsonp: Jsonp, private route: ActivatedRoute, public save: SaveService) {
const arena_url = new URL('https://mycard.moe/ygopro/arena');
arena_url.searchParams.set('sso', login.token);
......
import { Observable } from 'rxjs/Observable';
// import { bindCallback as staticBindCallback } from '../../observable/bindCallback';
declare module 'rxjs/Observable' {
interface Observable<T> {
[Symbol.asyncIterator](): AsyncIterator<T>;
}
}
class Deferred<T> extends Promise<T> {
resolve;
reject;
constructor() {
let a, b;
super((resolve, reject) => {
a = resolve;
b = reject;
});
this.resolve = a;
this.reject = b;
}
}
Observable.prototype[Symbol.asyncIterator] = async function*() {
let deferred = new Deferred();
const completed = Symbol('completed');
this.subscribe({
next(value){
deferred.resolve(value);
},
error(error){
deferred.reject(error);
},
complete() {
deferred.resolve(completed);
},
});
let value;
while ((value = await deferred) != completed) {
deferred = new Deferred();
yield value;
}
};
......@@ -4,7 +4,7 @@
<meta charset="utf-8">
<title>MyCard Mobile</title>
<base href="/mobile/index.html">
<meta name="theme-color" content="#4285f4">
<meta name="theme-color" content="#673ab7">
<meta name="viewport" content="width=device-width, initial-scale=1">
<style>
......
......@@ -11,11 +11,12 @@
"target": "es5",
"strict": true,
"suppressImplicitAnyIndexErrors": true,
"noImplicitAny": false,
"typeRoots": [
"node_modules/@types"
],
"lib": [
"es2017",
"esnext",
"dom.iterable"
]
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment