summaryrefslogtreecommitdiff
path: root/src/web/app
diff options
context:
space:
mode:
Diffstat (limited to 'src/web/app')
-rw-r--r--src/web/app/mobile/api/input.ts5
-rw-r--r--src/web/app/mobile/script.ts3
-rw-r--r--src/web/app/mobile/views/components/ui.nav.vue1
-rw-r--r--src/web/app/mobile/views/pages/othello.vue16
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>