Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/remove js #10480

Merged
merged 3 commits into from
Apr 7, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions themes-default/slim/src/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,11 @@ import { App } from './components';
Vue.config.devtools = true;
Vue.config.performance = true;

if (document.body.getAttribute('developer') === 'True') {
Vue.config.devtools = true;
Vue.config.performance = true;
}

registerPlugins();

// @TODO: Remove this before v1.0.0
Expand Down
18 changes: 11 additions & 7 deletions themes-default/slim/src/components/backstretch.vue
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@ export default {
},
data() {
return {
created: false
created: false,
wrapper: null
};
},
computed: {
Expand Down Expand Up @@ -53,21 +54,24 @@ export default {
$wrap.css('top', offset);
$wrap.css('opacity', opacity).fadeIn(500);
this.created = true;
this.wrapper = $wrap;
}
},
removeBackStretch() {
if (this.created) {
$.backstretch('destroy');
this.created = false;
}
}
},
destroyed() {
if (this.created) {
$.backstretch('destroy');
}
this.removeBackStretch();
},
activated() {
this.setBackStretch();
},
deactivated() {
if (this.created) {
$.backstretch('destroy');
}
this.removeBackStretch();
},
watch: {
opacity(newOpacity) {
Expand Down
1 change: 1 addition & 0 deletions themes-default/slim/src/components/display-show.vue
Original file line number Diff line number Diff line change
Expand Up @@ -377,6 +377,7 @@

<script>
import debounce from 'lodash/debounce';
import Vue from 'vue';
import { mapState, mapGetters, mapActions } from 'vuex';
import { AppLink, PlotInfo, SceneNumberInput, SceneNumberAnimeInput } from './helpers';
import { humanFileSize } from '../utils/core';
Expand Down
5 changes: 1 addition & 4 deletions themes-default/slim/src/components/schedule/calendar.vue
Original file line number Diff line number Diff line change
Expand Up @@ -29,20 +29,17 @@
</ul>
</div>
</div>
<backstretch :slug="general.randomShowSlug" />
</div>
</template>
<script>
import { mapGetters, mapState } from 'vuex';
import { AppLink, Asset } from '../helpers';
import Backstretch from '../backstretch.vue';

export default {
name: 'calendar',
components: {
AppLink,
Asset,
Backstretch
Asset
},
computed: {
...mapState({
Expand Down
3 changes: 2 additions & 1 deletion themes-default/slim/src/components/subtitle-search.vue
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,8 @@ export default {
},
computed: {
...mapState({
general: state => state.config.general
general: state => state.config.general,
client: state => state.auth.client
}),
...mapGetters({
getLastReleaseName: 'getLastReleaseName'
Expand Down
37 changes: 0 additions & 37 deletions themes-default/slim/static/js/add-show-options.js

This file was deleted.

43 changes: 0 additions & 43 deletions themes-default/slim/static/js/blackwhite.js

This file was deleted.

157 changes: 0 additions & 157 deletions themes-default/slim/static/js/common/init.js

This file was deleted.

60 changes: 0 additions & 60 deletions themes-default/slim/static/js/config/init.js

This file was deleted.

Loading