diff --git a/assets/components/container/container.vue b/assets/components/container/container.vue index be4e0f08..6cfdfc12 100644 --- a/assets/components/container/container.vue +++ b/assets/components/container/container.vue @@ -18,7 +18,7 @@ export default { }; - diff --git a/assets/components/home/home.vue b/assets/components/home/home.vue index 87a8fe10..1b96920f 100644 --- a/assets/components/home/home.vue +++ b/assets/components/home/home.vue @@ -1,135 +1,153 @@ @@ -145,6 +163,9 @@ async function mounted() { export default { data() { return { + showLesbian: true, + showGay: false, + showTrans: false, releases: [], }; }, @@ -158,6 +179,47 @@ export default { diff --git a/assets/css/_states.scss b/assets/css/_states.scss new file mode 100644 index 00000000..51fc87f3 --- /dev/null +++ b/assets/css/_states.scss @@ -0,0 +1,7 @@ +.noselect { + user-select: none; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + -webkit-tap-highlight-color: transparent; +} diff --git a/assets/css/style.scss b/assets/css/style.scss index 4626b95b..2d6d2a33 100644 --- a/assets/css/style.scss +++ b/assets/css/style.scss @@ -1,4 +1,5 @@ @import 'theme'; +@import 'states'; html, body { diff --git a/assets/img/filter.svg b/assets/img/filter.svg new file mode 100644 index 00000000..121ca3dc --- /dev/null +++ b/assets/img/filter.svg @@ -0,0 +1,5 @@ + + +filter + + diff --git a/assets/js/main.js b/assets/js/main.js index 98c8466d..f3ad6bd3 100644 --- a/assets/js/main.js +++ b/assets/js/main.js @@ -7,11 +7,15 @@ import initStore from './store'; import '../css/style.scss'; import Container from '../components/container/container.vue'; +import Icon from '../components/icon/icon.vue'; function init() { const store = initStore(router); Vue.mixin({ + components: { + Icon, + }, watch: { pageTitle(title) { if (title) { diff --git a/public/css/style.css b/public/css/style.css index 5a74caa7..7f0222ec 100644 --- a/public/css/style.css +++ b/public/css/style.css @@ -1,3 +1,37 @@ +.filters-bar[data-v-5533e378] { + display: block; + background: rgba(0, 0, 0, 0.1); + padding: .5rem 1rem; +} +.filters-bar .icon[data-v-5533e378] { + fill: rgba(0, 0, 0, 0.5); +} +.filters[data-v-5533e378] { + display: inline-block; + list-style: none; + padding: .5rem; + margin: 0; +} +.filters .toggle[data-v-5533e378] { + color: rgba(0, 0, 0, 0.5); + background: rgba(0, 0, 0, 0.1); + box-sizing: border-box; + padding: .5rem; + border-radius: .5rem; + font-size: .9rem; + font-weight: bold; + cursor: pointer; +} +.filters .toggle .check[data-v-5533e378] { + display: none; +} +.filters .toggle.active[data-v-5533e378] { + color: #fff; + background: #ff886c; +} +.filter[data-v-5533e378] { + display: inline-block; +} .scenes[data-v-5533e378] { display: grid; grid-template-columns: repeat(auto-fit, minmax(20rem, 1fr)); @@ -148,6 +182,13 @@ width: .6rem; } +.noselect { + user-select: none; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + -webkit-tap-highlight-color: transparent; } + html, body { height: 100%; } @@ -182,17 +223,40 @@ body { margin: 0; } -.container[data-v-4f86a868] { +.container { height: 100%; display: flex; flex-direction: column; overflow: hidden; } -.content[data-v-4f86a868] { +.content { + display: flex; + flex-direction: column; flex-grow: 1; + overflow: hidden; +} +.content-inner { + flex-grow: 1; + padding: 1rem; overflow-y: auto; } -.content-inner[data-v-4f86a868] { - padding: 1rem; + +.icon { + fill: #222; + display: inline-block; + flex-shrink: 0; + width: 1rem; + height: 1rem; +} +.icon svg { + width: 100%; + height: 100%; +} +.icon.active { + fill: rgba(0, 0, 0, 0.5); +} +.icon.active:hover { + fill: #222; + cursor: pointer; } diff --git a/src/fetch-releases.js b/src/fetch-releases.js index b41c04d7..bf8ff8b9 100644 --- a/src/fetch-releases.js +++ b/src/fetch-releases.js @@ -337,6 +337,8 @@ async function fetchReleases() { const accumulatedScenes = scenesPerSite.reduce((acc, siteScenes) => ([...acc, ...siteScenes]), []); const sortedScenes = accumulatedScenes.sort(({ date: dateA }, { date: dateB }) => moment(dateB).diff(dateA)); + knex.destroy(); + return sortedScenes; }