2019-03-03 13:15:41 +00:00
|
|
|
<template>
|
2019-07-05 07:17:44 +00:00
|
|
|
<div
|
|
|
|
v-if="!showNothing"
|
2020-10-19 16:38:49 +00:00
|
|
|
class="ScopeSelector"
|
2020-10-20 21:31:16 +00:00
|
|
|
>
|
2020-11-24 12:52:01 +00:00
|
|
|
<button
|
2019-07-05 07:17:44 +00:00
|
|
|
v-if="showDirect"
|
2020-11-24 12:52:01 +00:00
|
|
|
class="button-unstyled scope"
|
2019-07-05 07:17:44 +00:00
|
|
|
:class="css.direct"
|
|
|
|
:title="$t('post_status.scope.direct')"
|
2021-02-01 19:07:09 +00:00
|
|
|
type="button"
|
2021-02-25 12:32:21 +00:00
|
|
|
@click="changeVis('direct')"
|
2020-10-20 21:31:16 +00:00
|
|
|
>
|
|
|
|
<FAIcon
|
|
|
|
icon="envelope"
|
2020-10-28 19:31:16 +00:00
|
|
|
class="fa-scale-110 fa-old-padding"
|
2020-10-20 21:31:16 +00:00
|
|
|
/>
|
2020-11-24 12:52:01 +00:00
|
|
|
</button>
|
|
|
|
<button
|
2019-07-05 07:17:44 +00:00
|
|
|
v-if="showPrivate"
|
2020-11-24 12:52:01 +00:00
|
|
|
class="button-unstyled scope"
|
2019-07-05 07:17:44 +00:00
|
|
|
:class="css.private"
|
|
|
|
:title="$t('post_status.scope.private')"
|
2021-02-01 19:07:09 +00:00
|
|
|
type="button"
|
2021-02-25 12:32:21 +00:00
|
|
|
@click="changeVis('private')"
|
2020-10-20 21:31:16 +00:00
|
|
|
>
|
|
|
|
<FAIcon
|
|
|
|
icon="lock"
|
2020-10-28 19:31:16 +00:00
|
|
|
class="fa-scale-110 fa-old-padding"
|
2020-10-20 21:31:16 +00:00
|
|
|
/>
|
2020-11-24 12:52:01 +00:00
|
|
|
</button>
|
|
|
|
<button
|
2019-07-05 07:17:44 +00:00
|
|
|
v-if="showUnlisted"
|
2020-11-24 12:52:01 +00:00
|
|
|
class="button-unstyled scope"
|
2019-07-05 07:17:44 +00:00
|
|
|
:class="css.unlisted"
|
|
|
|
:title="$t('post_status.scope.unlisted')"
|
2021-02-01 19:07:09 +00:00
|
|
|
type="button"
|
2021-02-25 12:32:21 +00:00
|
|
|
@click="changeVis('unlisted')"
|
2020-10-20 21:31:16 +00:00
|
|
|
>
|
|
|
|
<FAIcon
|
|
|
|
icon="lock-open"
|
2020-10-28 19:31:16 +00:00
|
|
|
class="fa-scale-110 fa-old-padding"
|
2020-10-20 21:31:16 +00:00
|
|
|
/>
|
2020-11-24 12:52:01 +00:00
|
|
|
</button>
|
|
|
|
<button
|
2019-07-05 07:17:44 +00:00
|
|
|
v-if="showPublic"
|
2020-11-24 12:52:01 +00:00
|
|
|
class="button-unstyled scope"
|
2019-07-05 07:17:44 +00:00
|
|
|
:class="css.public"
|
|
|
|
:title="$t('post_status.scope.public')"
|
2021-02-01 19:07:09 +00:00
|
|
|
type="button"
|
2021-02-25 12:32:21 +00:00
|
|
|
@click="changeVis('public')"
|
2020-10-20 21:31:16 +00:00
|
|
|
>
|
|
|
|
<FAIcon
|
|
|
|
icon="globe"
|
2020-10-28 19:31:16 +00:00
|
|
|
class="fa-scale-110 fa-old-padding"
|
2020-10-20 21:31:16 +00:00
|
|
|
/>
|
2020-11-24 12:52:01 +00:00
|
|
|
</button>
|
2021-07-01 15:06:59 +00:00
|
|
|
<button
|
|
|
|
v-if="showLocal"
|
|
|
|
class="button-unstyled scope"
|
|
|
|
:class="css.local"
|
|
|
|
:title="$t('post_status.scope.local')"
|
|
|
|
type="button"
|
|
|
|
@click="changeVis('local')"
|
|
|
|
>
|
|
|
|
<FAIcon
|
|
|
|
icon="users"
|
|
|
|
class="fa-scale-110 fa-old-padding"
|
|
|
|
/>
|
|
|
|
</button>
|
2019-07-05 07:17:44 +00:00
|
|
|
</div>
|
2019-03-03 13:15:41 +00:00
|
|
|
</template>
|
|
|
|
|
|
|
|
<script src="./scope_selector.js"></script>
|
2019-05-15 20:51:30 +00:00
|
|
|
|
|
|
|
<style lang="scss">
|
|
|
|
@import '../../_variables.scss';
|
|
|
|
|
2020-10-19 16:38:49 +00:00
|
|
|
.ScopeSelector {
|
|
|
|
|
|
|
|
.scope {
|
|
|
|
display: inline-block;
|
2019-05-15 20:51:30 +00:00
|
|
|
cursor: pointer;
|
2020-10-19 16:38:49 +00:00
|
|
|
min-width: 1.3em;
|
|
|
|
min-height: 1.3em;
|
|
|
|
text-align: center;
|
2022-12-03 07:12:55 +00:00
|
|
|
margin-right: 0.4em;
|
2019-05-15 20:51:30 +00:00
|
|
|
|
2020-10-19 16:38:49 +00:00
|
|
|
&.selected svg {
|
2019-05-15 20:51:30 +00:00
|
|
|
color: $fallback--lightText;
|
|
|
|
color: var(--lightText, $fallback--lightText);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
</style>
|