diff options
| author | syuilo <Syuilotan@yahoo.co.jp> | 2018-03-07 19:00:15 +0900 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2018-03-07 19:00:15 +0900 |
| commit | a227ef30e8bc8282605361b013d323bb3bbc4e7d (patch) | |
| tree | 8bd28f1d27a77e061e7b7f56f8794e483fe82f8f /src/web/app/mobile | |
| parent | v3999 (diff) | |
| parent | oops (diff) | |
| download | sharkey-a227ef30e8bc8282605361b013d323bb3bbc4e7d.tar.gz sharkey-a227ef30e8bc8282605361b013d323bb3bbc4e7d.tar.bz2 sharkey-a227ef30e8bc8282605361b013d323bb3bbc4e7d.zip | |
Merge pull request #1197 from syuilo/othello
Othello
Diffstat (limited to 'src/web/app/mobile')
| -rw-r--r-- | src/web/app/mobile/api/input.ts | 5 | ||||
| -rw-r--r-- | src/web/app/mobile/script.ts | 3 | ||||
| -rw-r--r-- | src/web/app/mobile/views/components/ui.nav.vue | 1 | ||||
| -rw-r--r-- | src/web/app/mobile/views/pages/othello.vue | 16 |
4 files changed, 24 insertions, 1 deletions
diff --git a/src/web/app/mobile/api/input.ts b/src/web/app/mobile/api/input.ts index fcff68cfb6..38d0fb61eb 100644 --- a/src/web/app/mobile/api/input.ts +++ b/src/web/app/mobile/api/input.ts @@ -1,5 +1,8 @@ export default function(opts) { return new Promise<string>((res, rej) => { - alert('input not implemented yet'); + const x = window.prompt(opts.title); + if (x) { + res(x); + } }); } diff --git a/src/web/app/mobile/script.ts b/src/web/app/mobile/script.ts index eeadfd92b0..27c18c5ae1 100644 --- a/src/web/app/mobile/script.ts +++ b/src/web/app/mobile/script.ts @@ -4,6 +4,7 @@ // Style import './style.styl'; +import '../../element.scss'; import init from '../init'; @@ -28,6 +29,7 @@ import MkFollowers from './views/pages/followers.vue'; import MkFollowing from './views/pages/following.vue'; import MkSettings from './views/pages/settings.vue'; import MkProfileSetting from './views/pages/profile-setting.vue'; +import MkOthello from './views/pages/othello.vue'; /** * init @@ -67,6 +69,7 @@ init((launch) => { { path: '/i/drive/file/:file', component: MkDrive }, { path: '/selectdrive', component: MkSelectDrive }, { path: '/search', component: MkSearch }, + { path: '/game/othello', component: MkOthello }, { path: '/:user', component: MkUser }, { path: '/:user/followers', component: MkFollowers }, { path: '/:user/following', component: MkFollowing }, diff --git a/src/web/app/mobile/views/components/ui.nav.vue b/src/web/app/mobile/views/components/ui.nav.vue index 62ea83526f..a58225a172 100644 --- a/src/web/app/mobile/views/components/ui.nav.vue +++ b/src/web/app/mobile/views/components/ui.nav.vue @@ -18,6 +18,7 @@ <li><router-link to="/">%fa:home%%i18n:mobile.tags.mk-ui-nav.home%%fa:angle-right%</router-link></li> <li><router-link to="/i/notifications">%fa:R bell%%i18n:mobile.tags.mk-ui-nav.notifications%<template v-if="hasUnreadNotifications">%fa:circle%</template>%fa:angle-right%</router-link></li> <li><router-link to="/i/messaging">%fa:R comments%%i18n:mobile.tags.mk-ui-nav.messaging%<template v-if="hasUnreadMessagingMessages">%fa:circle%</template>%fa:angle-right%</router-link></li> + <li><router-link to="/game/othello">%fa:gamepad%ゲーム%fa:angle-right%</router-link></li> </ul> <ul> <li><a :href="chUrl" target="_blank">%fa:tv%%i18n:mobile.tags.mk-ui-nav.ch%%fa:angle-right%</a></li> diff --git a/src/web/app/mobile/views/pages/othello.vue b/src/web/app/mobile/views/pages/othello.vue new file mode 100644 index 0000000000..67f4add07f --- /dev/null +++ b/src/web/app/mobile/views/pages/othello.vue @@ -0,0 +1,16 @@ +<template> +<mk-ui> + <span slot="header">%fa:gamepad%オセロ</span> + <mk-othello/> +</mk-ui> +</template> + +<script lang="ts"> +import Vue from 'vue'; +export default Vue.extend({ + mounted() { + document.title = 'Misskey オセロ'; + document.documentElement.style.background = '#fff'; + } +}); +</script> |