Commit 71e1cfb2 authored by mahui's avatar mahui

ss

parent 6580afb8
{
"presets": [
["env", {
"modules": false,
"targets": {
"browsers": ["> 1%", "last 2 versions", "not ie <= 8"]
}
}],
"stage-2"
],
"plugins": ["transform-vue-jsx", "transform-runtime"],
"env": {
"test": {
"presets": ["env", "stage-2"],
"plugins": ["transform-vue-jsx", "transform-es2015-modules-commonjs", "dynamic-import-node"]
}
}
}
root = true
[*]
charset = utf-8
indent_style = tab
indent_size = 4
end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true
*.vue
*.js
\ No newline at end of file
.DS_Store
node_modules/
/dist/
/src/video/
npm-debug.log*
yarn-debug.log*
yarn-error.log*
/test/unit/coverage/
# Editor directories and files
.idea
.vscode
*.suo
*.ntvs*
*.njsproj
*.sln
/static/video
// https://github.com/michael-ciniawsky/postcss-load-config
module.exports = {
"plugins": {
"postcss-import": {},
"postcss-url": {},
// to edit target browsers: use "browserslist" field in package.json
"autoprefixer": {}
}
}
# sitang
> sitangProject
## Build Setup
``` bash
# install dependencies
npm install
# serve with hot reload at localhost:8080
npm run dev
# build for production with minification
npm run build
# build for production and view the bundle analyzer report
npm run build --report
# run unit tests
npm run unit
# run all tests
npm test
```
For a detailed explanation on how things work, check out the [guide](http://vuejs-templates.github.io/webpack/) and [docs for vue-loader](http://vuejs.github.io/vue-loader).
'use strict'
require('./check-versions')()
process.env.NODE_ENV = 'production'
const ora = require('ora')
const rm = require('rimraf')
const path = require('path')
const chalk = require('chalk')
const webpack = require('webpack')
const config = require('../config')
const webpackConfig = require('./webpack.prod.conf')
const spinner = ora('building for production...')
spinner.start()
rm(path.join(config.build.assetsRoot, config.build.assetsSubDirectory), err => {
if (err) throw err
webpack(webpackConfig, (err, stats) => {
spinner.stop()
if (err) throw err
process.stdout.write(stats.toString({
colors: true,
modules: false,
children: false, // If you are using ts-loader, setting this to true will make TypeScript errors show up during build.
chunks: false,
chunkModules: false
}) + '\n\n')
if (stats.hasErrors()) {
console.log(chalk.red(' Build failed with errors.\n'))
process.exit(1)
}
console.log(chalk.cyan(' Build complete.\n'))
console.log(chalk.yellow(
' Tip: built files are meant to be served over an HTTP server.\n' +
' Opening index.html over file:// won\'t work.\n'
))
})
})
'use strict'
const chalk = require('chalk')
const semver = require('semver')
const packageConfig = require('../package.json')
const shell = require('shelljs')
function exec (cmd) {
return require('child_process').execSync(cmd).toString().trim()
}
const versionRequirements = [
{
name: 'node',
currentVersion: semver.clean(process.version),
versionRequirement: packageConfig.engines.node
}
]
if (shell.which('npm')) {
versionRequirements.push({
name: 'npm',
currentVersion: exec('npm --version'),
versionRequirement: packageConfig.engines.npm
})
}
module.exports = function () {
const warnings = []
for (let i = 0; i < versionRequirements.length; i++) {
const mod = versionRequirements[i]
if (!semver.satisfies(mod.currentVersion, mod.versionRequirement)) {
warnings.push(mod.name + ': ' +
chalk.red(mod.currentVersion) + ' should be ' +
chalk.green(mod.versionRequirement)
)
}
}
if (warnings.length) {
console.log('')
console.log(chalk.yellow('To use this template, you must update following to modules:'))
console.log()
for (let i = 0; i < warnings.length; i++) {
const warning = warnings[i]
console.log(' ' + warning)
}
console.log()
process.exit(1)
}
}
'use strict'
const path = require('path')
const config = require('../config')
const ExtractTextPlugin = require('extract-text-webpack-plugin')
const packageConfig = require('../package.json')
exports.assetsPath = function (_path) {
const assetsSubDirectory = process.env.NODE_ENV === 'production'
? config.build.assetsSubDirectory
: config.dev.assetsSubDirectory
return path.posix.join(assetsSubDirectory, _path)
}
exports.cssLoaders = function (options) {
options = options || {}
const cssLoader = {
loader: 'css-loader',
options: {
sourceMap: options.sourceMap
}
}
const postcssLoader = {
loader: 'postcss-loader',
options: {
sourceMap: options.sourceMap
}
}
// generate loader string to be used with extract text plugin
function generateLoaders (loader, loaderOptions) {
const loaders = options.usePostCSS ? [cssLoader, postcssLoader] : [cssLoader]
if (loader) {
loaders.push({
loader: loader + '-loader',
options: Object.assign({}, loaderOptions, {
sourceMap: options.sourceMap
})
})
}
// Extract CSS when that option is specified
// (which is the case during production build)
if (options.extract) {
return ExtractTextPlugin.extract({
use: loaders,
fallback: 'vue-style-loader'
})
} else {
return ['vue-style-loader'].concat(loaders)
}
}
// https://vue-loader.vuejs.org/en/configurations/extract-css.html
return {
css: generateLoaders(),
postcss: generateLoaders(),
less: generateLoaders('less'),
sass: generateLoaders('sass', { indentedSyntax: true }),
scss: generateLoaders('sass'),
stylus: generateLoaders('stylus'),
styl: generateLoaders('stylus')
}
}
// Generate loaders for standalone style files (outside of .vue)
exports.styleLoaders = function (options) {
const output = []
const loaders = exports.cssLoaders(options)
for (const extension in loaders) {
const loader = loaders[extension]
output.push({
test: new RegExp('\\.' + extension + '$'),
use: loader
})
}
return output
}
exports.createNotifierCallback = () => {
const notifier = require('node-notifier')
return (severity, errors) => {
if (severity !== 'error') return
const error = errors[0]
const filename = error.file && error.file.split('!').pop()
notifier.notify({
title: packageConfig.name,
message: severity + ': ' + error.name,
subtitle: filename || '',
icon: path.join(__dirname, 'logo.png')
})
}
}
'use strict'
const utils = require('./utils')
const config = require('../config')
const isProduction = process.env.NODE_ENV === 'production'
const sourceMapEnabled = isProduction
? config.build.productionSourceMap
: config.dev.cssSourceMap
module.exports = {
loaders: utils.cssLoaders({
sourceMap: sourceMapEnabled,
extract: isProduction
}),
cssSourceMap: sourceMapEnabled,
cacheBusting: config.dev.cacheBusting,
transformToRequire: {
video: ['src', 'poster'],
source: 'src',
img: 'src',
image: 'xlink:href'
}
}
'use strict'
const path = require('path')
const utils = require('./utils')
const config = require('../config')
const vueLoaderConfig = require('./vue-loader.conf')
function resolve (dir) {
return path.join(__dirname, '..', dir)
}
module.exports = {
context: path.resolve(__dirname, '../'),
entry: {
app: './src/main.js'
},
output: {
path: config.build.assetsRoot,
filename: '[name].js',
publicPath: process.env.NODE_ENV === 'production'
? config.build.assetsPublicPath
: config.dev.assetsPublicPath
},
resolve: {
extensions: ['.js', '.vue', '.json'],
alias: {
'vue$': 'vue/dist/vue.esm.js',
'@': resolve('src'),
}
},
module: {
rules: [
{
test: /\.vue$/,
loader: 'vue-loader',
options: vueLoaderConfig
},
{
test: /\.js$/,
loader: 'babel-loader',
include: [resolve('src'), resolve('test'), resolve('node_modules/webpack-dev-server/client')]
},
{
test: /\.(png|jpe?g|gif|svg)(\?.*)?$/,
loader: 'url-loader',
options: {
limit: 10000,
name: utils.assetsPath('img/[name].[hash:7].[ext]')
}
},
{
test: /\.(mp4|webm|ogg|mp3|wav|flac|aac)(\?.*)?$/,
loader: 'url-loader',
options: {
limit: 10000,
name: utils.assetsPath('media/[name].[hash:7].[ext]')
}
},
{
test: /\.(woff2?|eot|ttf|otf)(\?.*)?$/,
loader: 'url-loader',
options: {
limit: 10000,
name: utils.assetsPath('fonts/[name].[hash:7].[ext]')
}
}
]
},
node: {
// prevent webpack from injecting useless setImmediate polyfill because Vue
// source contains it (although only uses it if it's native).
setImmediate: false,
// prevent webpack from injecting mocks to Node native modules
// that does not make sense for the client
dgram: 'empty',
fs: 'empty',
net: 'empty',
tls: 'empty',
child_process: 'empty'
}
}
'use strict'
const utils = require('./utils')
const webpack = require('webpack')
const config = require('../config')
const merge = require('webpack-merge')
const path = require('path')
const baseWebpackConfig = require('./webpack.base.conf')
const CopyWebpackPlugin = require('copy-webpack-plugin')
const HtmlWebpackPlugin = require('html-webpack-plugin')
const FriendlyErrorsPlugin = require('friendly-errors-webpack-plugin')
const portfinder = require('portfinder')
const HOST = process.env.HOST
const PORT = process.env.PORT && Number(process.env.PORT)
const devWebpackConfig = merge(baseWebpackConfig, {
module: {
rules: utils.styleLoaders({ sourceMap: config.dev.cssSourceMap, usePostCSS: true })
},
// cheap-module-eval-source-map is faster for development
devtool: config.dev.devtool,
// these devServer options should be customized in /config/index.js
devServer: {
clientLogLevel: 'warning',
historyApiFallback: {
rewrites: [
{ from: /.*/, to: path.posix.join(config.dev.assetsPublicPath, 'index.html') },
],
},
hot: true,
contentBase: false, // since we use CopyWebpackPlugin.
compress: true,
host: HOST || config.dev.host,
port: PORT || config.dev.port,
open: config.dev.autoOpenBrowser,
overlay: config.dev.errorOverlay
? { warnings: false, errors: true }
: false,
publicPath: config.dev.assetsPublicPath,
proxy: config.dev.proxyTable,
quiet: true, // necessary for FriendlyErrorsPlugin
watchOptions: {
poll: config.dev.poll,
}
},
plugins: [
new webpack.DefinePlugin({
'process.env': require('../config/dev.env')
}),
new webpack.HotModuleReplacementPlugin(),
new webpack.NamedModulesPlugin(), // HMR shows correct file names in console on update.
new webpack.NoEmitOnErrorsPlugin(),
// https://github.com/ampedandwired/html-webpack-plugin
new HtmlWebpackPlugin({
filename: 'index.html',
template: 'index.html',
inject: true
}),
// copy custom static assets
new CopyWebpackPlugin([
{
from: path.resolve(__dirname, '../static'),
to: config.dev.assetsSubDirectory,
ignore: ['.*']
}
])
]
})
module.exports = new Promise((resolve, reject) => {
portfinder.basePort = process.env.PORT || config.dev.port
portfinder.getPort((err, port) => {
if (err) {
reject(err)
} else {
// publish the new Port, necessary for e2e tests
process.env.PORT = port
// add port to devServer config
devWebpackConfig.devServer.port = port
// Add FriendlyErrorsPlugin
devWebpackConfig.plugins.push(new FriendlyErrorsPlugin({
compilationSuccessInfo: {
messages: [`Your application is running here: http://${devWebpackConfig.devServer.host}:${port}`],
},
onErrors: config.dev.notifyOnErrors
? utils.createNotifierCallback()
: undefined
}))
resolve(devWebpackConfig)
}
})
})
'use strict'
const path = require('path')
const utils = require('./utils')
const webpack = require('webpack')
const config = require('../config')
const merge = require('webpack-merge')
const baseWebpackConfig = require('./webpack.base.conf')
const CopyWebpackPlugin = require('copy-webpack-plugin')
const HtmlWebpackPlugin = require('html-webpack-plugin')
const ExtractTextPlugin = require('extract-text-webpack-plugin')
const OptimizeCSSPlugin = require('optimize-css-assets-webpack-plugin')
const UglifyJsPlugin = require('uglifyjs-webpack-plugin')
const env = process.env.NODE_ENV === 'testing'
? require('../config/test.env')
: require('../config/prod.env')
const webpackConfig = merge(baseWebpackConfig, {
module: {
rules: utils.styleLoaders({
sourceMap: config.build.productionSourceMap,
extract: true,
usePostCSS: true
})
},
devtool: config.build.productionSourceMap ? config.build.devtool : false,
output: {
path: config.build.assetsRoot,
filename: utils.assetsPath('js/[name].[chunkhash].js'),
chunkFilename: utils.assetsPath('js/[id].[chunkhash].js')
},
plugins: [
// http://vuejs.github.io/vue-loader/en/workflow/production.html
new webpack.DefinePlugin({
'process.env': env
}),
new UglifyJsPlugin({
uglifyOptions: {
compress: {
warnings: false
}
},
sourceMap: config.build.productionSourceMap,
parallel: true
}),
// extract css into its own file
new ExtractTextPlugin({
filename: utils.assetsPath('css/[name].[contenthash].css'),
// Setting the following option to `false` will not extract CSS from codesplit chunks.
// Their CSS will instead be inserted dynamically with style-loader when the codesplit chunk has been loaded by webpack.
// It's currently set to `true` because we are seeing that sourcemaps are included in the codesplit bundle as well when it's `false`,
// increasing file size: https://github.com/vuejs-templates/webpack/issues/1110
allChunks: true,
}),
// Compress extracted CSS. We are using this plugin so that possible
// duplicated CSS from different components can be deduped.
new OptimizeCSSPlugin({
cssProcessorOptions: config.build.productionSourceMap
? { safe: true, map: { inline: false } }
: { safe: true }
}),
// generate dist index.html with correct asset hash for caching.
// you can customize output by editing /index.html
// see https://github.com/ampedandwired/html-webpack-plugin
new HtmlWebpackPlugin({
filename: process.env.NODE_ENV === 'testing'
? 'index.html'
: config.build.index,
template: 'index.html',
inject: true,
minify: {
removeComments: true,
collapseWhitespace: true,
removeAttributeQuotes: true
// more options:
// https://github.com/kangax/html-minifier#options-quick-reference
},
// necessary to consistently work with multiple chunks via CommonsChunkPlugin
chunksSortMode: 'dependency'
}),
// keep module.id stable when vendor modules does not change
new webpack.HashedModuleIdsPlugin(),
// enable scope hoisting
new webpack.optimize.ModuleConcatenationPlugin(),
// split vendor js into its own file
new webpack.optimize.CommonsChunkPlugin({
name: 'vendor',
minChunks (module) {
// any required modules inside node_modules are extracted to vendor
return (
module.resource &&
/\.js$/.test(module.resource) &&
module.resource.indexOf(
path.join(__dirname, '../node_modules')
) === 0
)
}
}),
// extract webpack runtime and module manifest to its own file in order to
// prevent vendor hash from being updated whenever app bundle is updated
new webpack.optimize.CommonsChunkPlugin({
name: 'manifest',
minChunks: Infinity
}),
// This instance extracts shared chunks from code splitted chunks and bundles them
// in a separate chunk, similar to the vendor chunk
// see: https://webpack.js.org/plugins/commons-chunk-plugin/#extra-async-commons-chunk
new webpack.optimize.CommonsChunkPlugin({
name: 'app',
async: 'vendor-async',
children: true,
minChunks: 3
}),
// copy custom static assets
new CopyWebpackPlugin([
{
from: path.resolve(__dirname, '../static'),
to: config.build.assetsSubDirectory,
ignore: ['.*']
}
])
]
})
if (config.build.productionGzip) {
const CompressionWebpackPlugin = require('compression-webpack-plugin')
webpackConfig.plugins.push(
new CompressionWebpackPlugin({
asset: '[path].gz[query]',
algorithm: 'gzip',
test: new RegExp(
'\\.(' +
config.build.productionGzipExtensions.join('|') +
')$'
),
threshold: 10240,
minRatio: 0.8
})
)
}
if (config.build.bundleAnalyzerReport) {
const BundleAnalyzerPlugin = require('webpack-bundle-analyzer').BundleAnalyzerPlugin
webpackConfig.plugins.push(new BundleAnalyzerPlugin())
}
module.exports = webpackConfig
'use strict'
const merge = require('webpack-merge')
const prodEnv = require('./prod.env')
module.exports = merge(prodEnv, {
NODE_ENV: '"development"'
})
'use strict'
// Template version: 1.3.1
// see http://vuejs-templates.github.io/webpack for documentation.
const path = require('path')
module.exports = {
dev: {
// Paths
assetsSubDirectory: 'static',
assetsPublicPath: '/',
proxyTable: {
},
// Various Dev Server settings
host: '127.0.0.98', // can be overwritten by process.env.HOST
port: 80, // can be overwritten by process.env.PORT, if port is in use, a free one will be determined
autoOpenBrowser: false,
errorOverlay: true,
notifyOnErrors: true,
poll: false, // https://webpack.js.org/configuration/dev-server/#devserver-watchoptions-
/**
* Source Maps
*/
// https://webpack.js.org/configuration/devtool/#development
devtool: 'cheap-module-eval-source-map',
// If you have problems debugging vue-files in devtools,
// set this to false - it *may* help
// https://vue-loader.vuejs.org/en/options.html#cachebusting
cacheBusting: true,
cssSourceMap: true
},
build: {
// Template for index.html
index: path.resolve(__dirname, '../dist/index.html'),
// Paths
assetsRoot: path.resolve(__dirname, '../dist'),
assetsSubDirectory: 'static',
assetsPublicPath: '/',
/**
* Source Maps
*/
productionSourceMap: true,
// https://webpack.js.org/configuration/devtool/#production
devtool: '#source-map',
// Gzip off by default as many popular static hosts such as
// Surge or Netlify already gzip all static assets for you.
// Before setting to `true`, make sure to:
// npm install --save-dev compression-webpack-plugin
productionGzip: false,
productionGzipExtensions: ['js', 'css'],
// Run the build command with an extra argument to
// View the bundle analyzer report after build finishes:
// `npm run build --report`
// Set to `true` or `false` to always turn it on or off
bundleAnalyzerReport: process.env.npm_config_report
}
}
'use strict'
module.exports = {
NODE_ENV: '"production"'
}
'use strict'
const merge = require('webpack-merge')
const devEnv = require('./dev.env')
module.exports = merge(devEnv, {
NODE_ENV: '"testing"'
})
[1223/212441.519:ERROR:directory_reader_win.cc(43)] FindFirstFile: 系统找不到指定的路径。 (0x3)
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1.0">
<title>检察院</title>
<script src="static/jquery-1.9.1.min.js"></script>
<script src="static/flashplay/ckplayer/ckplayer.js"></script>
<script src="static/webVideoCtrl.js"></script>
</head>
<body>
<div id="app"></div>
<!-- built files will be auto injected -->
</body>
</html>
This diff is collapsed.
{
"name": "sitang",
"version": "1.0.0",
"description": "sitangProject",
"author": "urey",
"private": true,
"scripts": {
"dev": "webpack-dev-server --inline --progress --config build/webpack.dev.conf.js",
"start": "npm run dev",
"unit": "jest --config test/unit/jest.conf.js --coverage",
"test": "npm run unit",
"build": "node build/build.js"
},
"dependencies": {
"axios": "^0.18.0",
"element-ui": "^2.4.11",
"es6-promise": "^4.2.8",
"vue": "^2.5.2",
"vue-router": "^3.0.1",
"vuex": "^3.0.1"
},
"devDependencies": {
"autoprefixer": "^7.1.2",
"babel-core": "^6.22.1",
"babel-helper-vue-jsx-merge-props": "^2.0.3",
"babel-jest": "^21.0.2",
"babel-loader": "^7.1.1",
"babel-plugin-dynamic-import-node": "^1.2.0",
"babel-plugin-syntax-jsx": "^6.18.0",
"babel-plugin-transform-es2015-modules-commonjs": "^6.26.0",
"babel-plugin-transform-runtime": "^6.22.0",
"babel-plugin-transform-vue-jsx": "^3.5.0",
"babel-preset-env": "^1.3.2",
"babel-preset-stage-2": "^6.22.0",
"chalk": "^2.0.1",
"copy-webpack-plugin": "^4.0.1",
"css-loader": "^0.28.0",
"extract-text-webpack-plugin": "^3.0.0",
"file-loader": "^1.1.4",
"friendly-errors-webpack-plugin": "^1.6.1",
"html-webpack-plugin": "^2.30.1",
"jest": "^22.0.4",
"jest-serializer-vue": "^0.3.0",
"node-notifier": "^5.1.2",
"optimize-css-assets-webpack-plugin": "^3.2.0",
"ora": "^1.2.0",
"portfinder": "^1.0.13",
"postcss-import": "^11.0.0",
"postcss-loader": "^2.0.8",
"postcss-url": "^7.2.1",
"rimraf": "^2.6.0",
"semver": "^5.3.0",
"shelljs": "^0.7.6",
"uglifyjs-webpack-plugin": "^1.1.1",
"url-loader": "^0.5.8",
"vue-jest": "^1.0.2",
"vue-loader": "^13.3.0",
"vue-style-loader": "^3.0.1",
"vue-template-compiler": "^2.5.2",
"webpack": "^3.6.0",
"webpack-bundle-analyzer": "^2.9.0",
"webpack-dev-server": "^2.9.1",
"webpack-merge": "^4.1.0"
},
"engines": {
"node": ">= 6.0.0",
"npm": ">= 3.0.0"
},
"browserslist": [
"> 1%",
"last 2 versions",
"not ie <= 8"
]
}
<template>
<div id="app">
<router-view/>
</div>
</template>
<script>
export default {
name: 'App'
}
</script>
<style>
@import 'assets/css/public.css';
#app {
font-family: 'Avenir', Helvetica, Arial, sans-serif;
text-align: center;
}
</style>
body {
overflow: hidden;
}
body,
html {
width: 100%;
height: 100%;
font-family: Helvetica Neue For Number, -apple-system, BlinkMacSystemFont, Segoe UI, Roboto, PingFang SC, Hiragino Sans GB, Microsoft YaHei, Helvetica Neue, Helvetica, Arial, sans-serif;
}
body,
html,
ul,
ol,
li,
a,
div,
input,
p,
textarea,
button {
padding: 0;
margin: 0;
list-style: none;
font-style: normal;
text-decoration: none;
border: none;
font-family: "Microsoft Yahei", sans-serif;
outline: none;
}
input,
textarea {
font-size: .16rem;
padding: 0;
}
// The Vue build version to load with the `import` command
// (runtime-only or standalone) has been set in webpack.base.conf with an alias.
import Vue from 'vue'
import App from './App'
import router from './router'
require('es6-promise').polyfill();
Vue.config.productionTip = false
/* eslint-disable no-new */
new Vue({
el: '#app',
router,
components: { App },
template: '<App/>'
})
<template>
<div class="firstPage">
<ul class="imgList">
<li :class="'item item_'+index"v-for="(item,index) in imgList" :key="index" @click="toPath(index)">
<img class="img" :src="item.src" alt="">
<div class="cover">
<img src="static/play.png" alt="">
</div>
</li>
</ul>
</div>
</template>
<script>
export default {
name: 'HelloWorld',
data () {
return {
imgList:[
{
src:'static/animal.png',
name:'动物实观'
},{
src:'static/welfare.png',
name:'公益案件'
},{
src:'static/scene.png',
name:'现场连线'
},{
src:'static/network.png',
name:'网络视频'
},
]
}
},
watch:{
},
created() {
},
methods: {
toPath:function (index) {
this.$router.push({path:'/second',query:{page:index}})
}
}
}
</script>
<style scoped>
.firstPage{
width: 1920px;
height: 1080px;
background:url("/static/firstPage.png") no-repeat center;
}
.firstPage .imgList{
position: absolute;
top: 485px;
width: 1920px;
margin: 0 auto;
}
.firstPage .imgList .item{
position: relative;
display: inline-block;
margin: 0 20px;
cursor: pointer;
left: 1px;
}
.firstPage .imgList .item .cover{
position: absolute;
left: 0;
right: 0;
top: 0;
bottom: 4px;
background-color:#000;
opacity: .5;
display: none;
border-radius: 10px;
filter: alpha(opacity=50);
}
.firstPage .imgList .item .cover img{
position: absolute;
left: 0;
right: 0;
top: 0;
bottom: 0;
margin: auto;
opacity: 1;
filter: alpha(opacity=100);
}
.firstPage .imgList .item:hover .cover{
display: block;
}
.firstPage .imgList .item .img{
width: 100%;
}
.firstPage .imgList .item_1{
left: 2px;
}
.firstPage .imgList .item_2{
left: 2px;
}
.firstPage .imgList .item_3{
left: 4px;
}
</style>
This diff is collapsed.
import Vue from 'vue'
import Router from 'vue-router'
import index from '../page/index.vue'
import second from '../page/secondPage.vue'
Vue.use(Router)
export default new Router({
routes: [{
path: '/',
name: 'index',
component: index
},{
path: '/second',
name: 'second',
component: second
}]
})
This diff is collapsed.
This diff is collapsed.
<?xml version="1.0" encoding="utf-8"?>
<ckplayer>
<style>
<pr_zip>{font color='#FFFFFF' face='NSimSun'}已加载[$prtage]%{/font}</pr_zip>
<!--
加载皮肤包进度提示的文字,[$prtage]会被替换成加载百分比
-->
<pr_load>{font color='#FFFFFF' face='NSimSun'}已加载[$prtage]%{/font}</pr_load>
<!--
当调用多段视频时,并且没有配置好各段视频的时间和字节数的情况下,播放器需要先读取各段视频的元数据进行计算,此时需要显示一个加载进度告诉用户已计算的情况。
-->
<pr_noload>{font color='#FFFFFF' face='NSimSun'}加载失败{/font}</pr_noload>
<!--
加载视频失败时显示的内容
-->
<pr_buffer>{font color='#FFFFFF' face='Arial'}[$buffer]%{/font}</pr_buffer>
<!--
视频缓冲时显示的提示,[$buffer]会被替换成缓冲的百分比数字部份
-->
<pr_play>{font color='#FFFFFF' face='NSimSun'}点击播放{/font}</pr_play>
<!--
鼠标经过播放按钮时的提示,支持html
-->
<pr_pause>{font color='#FFFFFF' face='NSimSun'}点击暂停{/font}</pr_pause>
<!--
鼠标经过暂停按钮时的提示,支持html
-->
<pr_mute>{font color='#FFFFFF' face='NSimSun'}点击静音{/font}</pr_mute>
<!--
鼠标经过静音按钮时的提示,支持html
-->
<pr_nomute>{font color='#FFFFFF' face='NSimSun'}取消静音{/font}</pr_nomute>
<!--
鼠标经过取消静音按钮时的提示,支持html
-->
<pr_full>{font color='#FFFFFF' face='NSimSun'}点击全屏{/font}</pr_full>
<!--
鼠标经过全屏按钮时的提示,支持html
-->
<pr_nofull>{font color='#FFFFFF' face='NSimSun'}退出全屏{/font}</pr_nofull>
<!--
鼠标经过退出全屏按钮时的提示,支持html
-->
<pr_fastf>{font color='#FFFFFF' face='NSimSun'}快进{/font}</pr_fastf>
<!--
鼠标经过快进按钮时的提示,支持html
-->
<pr_fastr>{font color='#FFFFFF' face='NSimSun'}快退{/font}</pr_fastr>
<!--
鼠标经过快退按钮时的提示,支持html
-->
<pr_time>{font color='#FFFFFF' face='Arial'}[$Time]{/font}</pr_time>
<!--
鼠标经过进度栏时提示当前点上时间的,[$Time]会被替换成时间,支持html
-->
<pr_volume>{font color='#FFFFFF' face='NSimSun'}音量[$Volume]%{/font}</pr_volume>
<!--
鼠标经过音量调节框或调整音量时提示,[$Volume]会自动替换音量值(0-100)
-->
<pr_clockwait>{font color='#FFFFFF' face='Arial'}00:00 | 00:00{/font}</pr_clockwait>
<!--
在默认不加载视频,即m=1的时候,同时并没有设置视频的时间和字节,即o和w值的时候,pr_clock和pr_clock2里的所有内容被替换成这里设置的值
-->
<pr_live>{font color='#FFFFFF' face='NSimSun'}视频直播中{/font}</pr_live>
<!--
在直播的情况下显示的文字
-->
<pr_adv>{font color='#FFFFFF' size='12'}广告剩余:{font color='#FF0000' size='15'}{b}[$Second]{/b}{/font} 秒{/font}</pr_adv>
<!--
广告倒计时显示的内容,[$Second]将会显示倒计时的秒数
-->
</style>
</ckplayer>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<ckplayer>
<title>{font color="#FFDD00" face="新宋体"}精彩视频推荐{/font}</title>
<!--左上角的标题说明文字,支持html-->
<area>600,400,0xFFDD00,20</area>
<!--
该插件在播放中的区域控制
固定尺寸,精彩视频区域会固定大小并且保持剧中
1:宽
2:高
3:边框色
4:边框透明度
-->
<image>120,90</image>
<!--图片的宽,高-->
<distance>150,175,100</distance>
<!--
1:横排图片之间的距离,前一个图片的左边到后一个图片的左边的距离
2:竖排图片之间距离,上一个图片的上边到下一个图片的上边距离,这里需要特别注意,因为图片显示区域是总区域-40的高度,默认的即<area>的高400-40=360,所以比如你的图片想一列显示二个,则该参数需要设置成360/2=180
3:文字距离图片上方的距离
只要设置好这三个参数,图片的位置就可以固定住了
-->
<rep_title>{a href="[url]" target="_blank"}{font color="#FFFFFF" face="新宋体"}[title]{/font}{/a}</rep_title>
<!--标题替换规则-->
<style>a{color:#FFFFFF;}a:hover{color:#FF0000;}</style>
<!--文本样式-->
<size>120,42,3</size>
<!--文本的宽度,高度,行和行之间距离-->
<relatedlist>
<related>
<img>temp/1.jpg</img>
<url>http://www.ckplayer.com/index.php?id=1</url>
<title>1:这里调用的文件配置在ckplayer/related.xml里</title>
</related>
<related>
<img>temp/2.jpg</img>
<url>http://www.ckplayer.com/index.php?id=2</url>
<title>2:支持多页调用</title>
</related>
<related>
<img>temp/3.jpg</img>
<url>http://www.ckplayer.com/index.php?id=3</url>
<title>3:文本请保持在二行,不能多于三行,多于三行将不显示</title>
</related>
<related>
<img>temp/4.jpg</img>
<url>http://www.ckplayer.com/index.php?id=3</url>
<title>4:支持多行调用,多页调用</title>
</related>
<related>
<img>temp/5.jpg</img>
<url>http://www.ckplayer.com/index.php?id=2</url>
<title>5:感谢对ckplayer的支持</title>
</related>
<related>
<img>temp/6.jpg</img>
<url>http://www.ckplayer.com/index.php?id=1</url>
<title>6:最多两行,请不要超过二行</title>
</related>
<related>
<img>temp/3.jpg</img>
<url>http://www.ckplayer.com/index.php?id=1</url>
<title>7:这里调用的文件配置在ckplayer/related.xml里</title>
</related>
<related>
<img>temp/5.jpg</img>
<url>http://www.ckplayer.com/index.php?id=2</url>
<title>8:支持多页调用</title>
</related>
<related>
<img>temp/4.jpg</img>
<url>http://www.ckplayer.com/index.php?id=3</url>
<title>9:文本请保持在二行,不能多于三行,多于三行将不显示</title>
</related>
<related>
<img>temp/1.jpg</img>
<url>http://www.ckplayer.com/index.php?id=3</url>
<title>10:支持多行调用,多页调用</title>
</related>
<related>
<img>temp/2.jpg</img>
<url>http://www.ckplayer.com/index.php?id=2</url>
<title>11:感谢对ckplayer的支持</title>
</related>
<related>
<img>temp/6.jpg</img>
<url>http://www.ckplayer.com/index.php?id=1</url>
<title>12:最多两行,请不要超过二行</title>
</related>
<related>
<img>temp/5.jpg</img>
<url>http://www.ckplayer.com/index.php?id=1</url>
<title>13:这里调用的文件配置在ckplayer/related.xml里</title>
</related>
<related>
<img>temp/4.jpg</img>
<url>http://www.ckplayer.com/index.php?id=2</url>
<title>14:支持多页调用</title>
</related>
<related>
<img>temp/6.jpg</img>
<url>http://www.ckplayer.com/index.php?id=3</url>
<title>15:文本请保持在二行,不能多于三行,多于三行将不显示</title>
</related>
<related>
<img>temp/3.jpg</img>
<url>http://www.ckplayer.com/index.php?id=3</url>
<title>16:支持多行调用,多页调用</title>
</related>
<related>
<img>temp/1.jpg</img>
<url>http://www.ckplayer.com/index.php?id=2</url>
<title>17:感谢对ckplayer的支持</title>
</related>
<related>
<img>temp/2.jpg</img>
<url>http://www.ckplayer.com/index.php?id=1</url>
<title>18:最多两行,请不要超过二行</title>
</related>
</relatedlist>
</ckplayer>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<ckplayer>
<share_html>
{embed src="贵站网址,在ckplayer/share.xml里修改/ckplayer/ckplayer.swf" flashvars="[$share]" quality="high" width="480" height="400" align="middle" allowScriptAccess="always" allowFullscreen="true" type="application/x-shockwave-flash"}{/embed}
</share_html>
<share_flash>
贵站网址/ckplayer/ckplayer.swf?[$share]
</share_flash>
<share_flashvars>
f,my_url,my_pic,a
</share_flashvars>
<share_path>ckplayer/share/</share_path><!--分享图片的文件夹地址-->
<share_replace>
</share_replace>
<share_permit>0</share_permit><!--是否有视听许可证,默认0没有,1是有-->
<share_uuid>
c25cf02c-1705-412d-bd4b-77a10b380f08
</share_uuid>
<share_button>
<share>
<id>qqmb</id>
<img>qq.png</img>
<coordinate>20,50</coordinate>
</share>
<share>
<id>sinaminiblog</id>
<img>sina.png</img>
<coordinate>101,50</coordinate>
</share>
<share>
<id>qzone</id>
<img>qzone.png</img>
<coordinate>182,50</coordinate>
</share>
<share>
<id>renren</id>
<img>rr.png</img>
<coordinate>263,50</coordinate>
</share>
<share>
<id>kaixin001</id>
<img>kaixin001.png</img>
<coordinate>20,85</coordinate>
</share>
<share>
<id>tianya</id>
<img>tianya.png</img>
<coordinate>101,85</coordinate>
</share>
<share>
<id>feixin</id>
<img>feixin.png</img>
<coordinate>182,85</coordinate>
</share>
<share>
<id>msn</id>
<img>msn.png</img>
<coordinate>263,85</coordinate>
</share>
</share_button>
</ckplayer>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<cross-domain-policy>
<allow-access-from domain="*"/>
</cross-domain-policy>
\ No newline at end of file
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>ckplayer 只调用flash播放器</title>
</head>
<body>
<div id="a1"></div>
<script type="text/javascript" src="ckplayer/ckplayer.js" charset="utf-8"></script>
<script type="text/javascript">
var flashvars={
f:'m3u8.swf',
a:'http://vshare.ys7.com/hcnp/554438733_1_2_4_0_cas.ys7.com_6500.m3u8?554438733_728af9e9d078422c9d95e641b0014c11_1_8fac2d2fff714b23',
c:0,
s:4,
lv:1//注意,如果是直播,需设置lv:1
}
var params={bgcolor:'#FFF',allowFullScreen:true,allowScriptAccess:'always',wmode:'transparent'};
CKobject.embedSWF('ckplayer/ckplayer.swf','a1','ckplayer_a1','600','400',flashvars,params);
function closelights(){//关灯
//alert(' 本演示不支持开关灯');
}
function openlights(){//开灯
//alert(' 本演示不支持开关灯');
}
</script>
</body>
</html>
/*
该文件是从网上收集的方法,用来做开关灯的,相对于原来的程序做了一些改变,兼容了IE10
*/
var Offlights = {
create: function() {
return function() {
this.initialize.apply(this, arguments)
}
}
}
var OverLay = Offlights.create();
OverLay.prototype = {
initialize: function(options) {
this.SetOptions(options);
this.browser = (function(ua){
var a=new Object();
var b = {
msie: /msie/.test(ua) && !/opera/.test(ua),
opera: /opera/.test(ua),
safari: /webkit/.test(ua) && !/chrome/.test(ua),
firefox: /firefox/.test(ua),
chrome: /chrome/.test(ua)
};
var vMark = "";
for (var i in b) {
if (b[i]) { vMark = "safari" == i ? "version" : i; break; }
}
b.version = vMark && RegExp("(?:" + vMark + ")[\\/: ]([\\d.]+)").test(ua) ? RegExp.$1 : "0";
b.ie = b.msie;
b.ie6 = b.msie && parseInt(b.version, 10) == 6;
b.ie7 = b.msie && parseInt(b.version, 10) == 7;
b.ie8 = b.msie && parseInt(b.version, 10) == 8;
a.B=vMark;
a.V=b.version;
return a;
})(window.navigator.userAgent.toLowerCase());
this.isIE = this.browser['B']=='msie' ? true : false;
this.isIE6 = (this.isIE && this.browser['V']==6)?true:false;
this._K_ = function(id) {return "string" == typeof id ? document.getElementById(id) : id};
this.Lay = this._K_(this.options.Lay) || document.body.insertBefore(document.createElement("div"), document.body.childNodes[0]);
this.Color = this.options.Color;
this.Opacity = parseInt(this.options.Opacity);
this.zIndex = parseInt(this.options.zIndex);
with(this.Lay.style) {
display = "none";
zIndex = this.zIndex;
left = top = 0;
position = "fixed";
width = height = "100%"
}
if (this.isIE6) {
this.Lay.style.position = "absolute";
this._resize = this.Bind(this,
function() {
this.Lay.style.width = Math.max(document.documentElement.scrollWidth, document.documentElement.clientWidth) + "px";
this.Lay.style.height = Math.max(document.documentElement.scrollHeight, document.documentElement.clientHeight) + "px"
});
this.Lay.innerHTML = ''
}
},
Bind:function(object, fun) {
return function() {
return fun.apply(object, arguments)
}
},
Extend :function(destination, source) {
for (var property in source) {
destination[property] = source[property]
}
},
SetOptions: function(options) {
this.options = {
Lay: null,
Color: "#000",
Opacity: 100,
zIndex: 50
};
this.Extend(this.options, options || {})
},
Show: function() {
if (this.isIE6) {
this._resize();
window.attachEvent("onresize", this._resize)
}
with(this.Lay.style) {
this.isIE ? filter = "alpha(opacity:" + this.Opacity + ")": opacity = this.Opacity / 100;
backgroundColor = this.Color;
display = "block"
}
},
Close: function() {
this.Lay.style.display = "none";
if (this.isIE6) {
window.detachEvent("onresize", this._resize)
}
}
};
var LightBox = Offlights.create();
LightBox.prototype = {
initialize: function(options) {
this.OverLay = new OverLay(options);
},
Show: function(options) {
this.OverLay.Show();
},
Close: function() {
this.OverLay.Close();
}
};
This diff is collapsed.
This source diff could not be displayed because it is too large. You can view the blob instead.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
<?xml version="1.0" encoding="utf-8"?>
<cross-domain-policy>
<allow-access-from domain="*"/>
</cross-domain-policy>
\ No newline at end of file
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment