Remove unused ft-grid component and __static variable (#2744)
* Remove unused ft-grid component * Remove unused __static variable
This commit is contained in:
parent
cffce405a4
commit
d8f7d073ce
|
@ -57,13 +57,7 @@ const config = {
|
||||||
target: 'electron-main',
|
target: 'electron-main',
|
||||||
}
|
}
|
||||||
|
|
||||||
if (isDevMode) {
|
if (!isDevMode) {
|
||||||
config.plugins.push(
|
|
||||||
new webpack.DefinePlugin({
|
|
||||||
__static: `"${path.join(__dirname, '../static').replace(/\\/g, '\\\\')}"`,
|
|
||||||
})
|
|
||||||
)
|
|
||||||
} else {
|
|
||||||
config.plugins.push(
|
config.plugins.push(
|
||||||
new CopyWebpackPlugin({
|
new CopyWebpackPlugin({
|
||||||
patterns: [
|
patterns: [
|
||||||
|
|
|
@ -145,14 +145,7 @@ const config = {
|
||||||
/**
|
/**
|
||||||
* Adjust rendererConfig for production settings
|
* Adjust rendererConfig for production settings
|
||||||
*/
|
*/
|
||||||
if (isDevMode) {
|
if (!isDevMode) {
|
||||||
// any dev only config
|
|
||||||
config.plugins.push(
|
|
||||||
new webpack.DefinePlugin({
|
|
||||||
__static: `"${path.join(__dirname, '../static').replace(/\\/g, '\\\\')}"`,
|
|
||||||
})
|
|
||||||
)
|
|
||||||
} else {
|
|
||||||
const processLocalesPlugin = new ProcessLocalesPlugin({
|
const processLocalesPlugin = new ProcessLocalesPlugin({
|
||||||
compress: true,
|
compress: true,
|
||||||
inputDir: path.join(__dirname, '../static/locales'),
|
inputDir: path.join(__dirname, '../static/locales'),
|
||||||
|
|
|
@ -160,18 +160,6 @@ const config = {
|
||||||
target: 'web',
|
target: 'web',
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Adjust web for production settings
|
|
||||||
*/
|
|
||||||
if (isDevMode) {
|
|
||||||
// any dev only config
|
|
||||||
config.plugins.push(
|
|
||||||
new webpack.DefinePlugin({
|
|
||||||
__static: `"${path.join(__dirname, '../static').replace(/\\/g, '\\\\')}"`,
|
|
||||||
})
|
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|
||||||
const processLocalesPlugin = new ProcessLocalesPlugin({
|
const processLocalesPlugin = new ProcessLocalesPlugin({
|
||||||
compress: false,
|
compress: false,
|
||||||
inputDir: path.join(__dirname, '../static/locales'),
|
inputDir: path.join(__dirname, '../static/locales'),
|
||||||
|
|
|
@ -18,17 +18,6 @@
|
||||||
|
|
||||||
<body>
|
<body>
|
||||||
<div id="app"></div>
|
<div id="app"></div>
|
||||||
<% if (process.env.NODE_ENV !== 'development') { %>
|
|
||||||
<!-- Set `__static` path to static files in production -->
|
|
||||||
<script>
|
|
||||||
try {
|
|
||||||
window.__static = require('path')
|
|
||||||
.join(__dirname, '/static')
|
|
||||||
.replace(/\\/g, '\\\\')
|
|
||||||
} catch {}
|
|
||||||
</script>
|
|
||||||
<% } %>
|
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
// This is the service worker with the Advanced caching
|
// This is the service worker with the Advanced caching
|
||||||
|
|
||||||
|
|
|
@ -302,10 +302,6 @@ function runApp() {
|
||||||
/* eslint-disable-next-line */
|
/* eslint-disable-next-line */
|
||||||
newWindow.loadFile(`${__dirname}/index.html`)
|
newWindow.loadFile(`${__dirname}/index.html`)
|
||||||
}
|
}
|
||||||
|
|
||||||
global.__static = path
|
|
||||||
.join(__dirname, '/static')
|
|
||||||
.replace(/\\/g, '\\\\')
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (typeof searchQueryText === 'string' && searchQueryText.length > 0) {
|
if (typeof searchQueryText === 'string' && searchQueryText.length > 0) {
|
||||||
|
|
|
@ -1,6 +0,0 @@
|
||||||
.ft-grid {
|
|
||||||
display: grid;
|
|
||||||
grid-template-columns: repeat(auto-fill, 240px);
|
|
||||||
justify-content: space-evenly;
|
|
||||||
grid-gap: 5px;
|
|
||||||
}
|
|
|
@ -1,5 +0,0 @@
|
||||||
import Vue from 'vue'
|
|
||||||
|
|
||||||
export default Vue.extend({
|
|
||||||
name: 'FtGrid'
|
|
||||||
})
|
|
|
@ -1,8 +0,0 @@
|
||||||
<template>
|
|
||||||
<div class="ft-grid">
|
|
||||||
<slot />
|
|
||||||
</div>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script src="./ft-grid.js" />
|
|
||||||
<style scoped src="./ft-grid.css" />
|
|
Loading…
Reference in New Issue