Skip to content

Commit

Permalink
添加项目展示模块,波浪效果
Browse files Browse the repository at this point in the history
  • Loading branch information
biaochenxuying committed Feb 17, 2019
1 parent 7284fbd commit a8138f9
Show file tree
Hide file tree
Showing 12 changed files with 1,934 additions and 545 deletions.
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,11 @@
- [x] 点赞与评论
- [x] 留言
- [x] 时间轴
- [x] 项目展示
- [x] 发文(支持 MarkDown 语法)
- [x] 文章详情展示(支持代码语法高亮)
- [X] 移动端适配
- [X] 网站波浪效果

## 2.2 待实现功能

Expand Down Expand Up @@ -71,6 +73,7 @@
- login 登录
- message 留言
- nav 导航
- project 项目
- register 注册
- slider 右边栏(博主 logo 、链接和标签等)
- timeLine 时间轴
Expand Down
218 changes: 109 additions & 109 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,127 +3,127 @@
"version": "0.1.0",
"private": true,
"dependencies": {
"antd": "^3.9.3",
"autoprefixer": "7.1.6",
"axios": "^0.18.0",
"babel-core": "6.26.0",
"babel-eslint": "7.2.3",
"babel-jest": "20.0.3",
"babel-loader": "7.1.2",
"babel-plugin-import": "^1.9.1",
"babel-preset-react-app": "^3.1.2",
"babel-runtime": "6.26.0",
"case-sensitive-paths-webpack-plugin": "2.1.1",
"chalk": "1.1.3",
"connected-react-router": "^4.5.0",
"css-loader": "0.28.7",
"dotenv": "4.0.0",
"dotenv-expand": "4.2.0",
"eslint": "4.10.0",
"eslint-config-react-app": "^2.1.0",
"eslint-loader": "1.9.0",
"eslint-plugin-flowtype": "2.39.1",
"eslint-plugin-import": "2.8.0",
"eslint-plugin-jsx-a11y": "5.1.1",
"eslint-plugin-react": "7.4.0",
"extract-text-webpack-plugin": "3.0.2",
"file-loader": "1.1.5",
"fs-extra": "3.0.1",
"highlight.js": "^9.12.0",
"html-webpack-plugin": "2.29.0",
"immutable": "^3.8.2",
"jest": "20.0.4",
"marked": "^0.5.1",
"object-assign": "4.1.1",
"postcss-flexbugs-fixes": "3.2.0",
"postcss-loader": "2.0.8",
"promise": "8.0.1",
"prop-types": "^15.6.2",
"raf": "3.4.0",
"react": "^16.5.2",
"react-addons-css-transition-group": "^15.6.2",
"react-app-rewire-less": "^2.1.3",
"react-app-rewired": "^1.6.2",
"react-dev-utils": "^5.0.2",
"react-dom": "^16.5.2",
"react-loadable": "^5.5.0",
"react-redux": "^5.0.7",
"react-router": "^4.3.1",
"react-router-dom": "^4.3.1",
"react-scripts": "^1.1.5",
"react-transition-group": "^2.5.0",
"redux": "^4.0.0",
"redux-immutable": "^4.0.0",
"redux-thunk": "^2.3.0",
"resolve": "1.6.0",
"style-loader": "0.19.0",
"sw-precache-webpack-plugin": "0.11.4",
"url-loader": "0.6.2",
"webpack": "3.8.1",
"webpack-dev-server": "2.11.3",
"webpack-manifest-plugin": "1.3.2",
"whatwg-fetch": "2.0.3"
"antd": "^3.9.3",
"autoprefixer": "7.1.6",
"axios": "^0.18.0",
"babel-core": "6.26.0",
"babel-eslint": "7.2.3",
"babel-jest": "20.0.3",
"babel-loader": "7.1.2",
"babel-plugin-import": "^1.9.1",
"babel-preset-react-app": "^3.1.2",
"babel-runtime": "6.26.0",
"case-sensitive-paths-webpack-plugin": "2.1.1",
"chalk": "1.1.3",
"connected-react-router": "^4.5.0",
"css-loader": "0.28.7",
"dotenv": "4.0.0",
"dotenv-expand": "4.2.0",
"eslint": "4.10.0",
"eslint-config-react-app": "^2.1.0",
"eslint-loader": "1.9.0",
"eslint-plugin-flowtype": "2.39.1",
"eslint-plugin-import": "2.8.0",
"eslint-plugin-jsx-a11y": "5.1.1",
"eslint-plugin-react": "7.4.0",
"extract-text-webpack-plugin": "3.0.2",
"file-loader": "1.1.5",
"fs-extra": "3.0.1",
"highlight.js": "^9.12.0",
"html-webpack-plugin": "2.29.0",
"immutable": "^3.8.2",
"jest": "20.0.4",
"marked": "^0.5.1",
"object-assign": "4.1.1",
"postcss-flexbugs-fixes": "3.2.0",
"postcss-loader": "2.0.8",
"promise": "8.0.1",
"prop-types": "^15.6.2",
"raf": "3.4.0",
"react": "^16.5.2",
"react-addons-css-transition-group": "^15.6.2",
"react-app-rewire-less": "^2.1.3",
"react-app-rewired": "^1.6.2",
"react-dev-utils": "^5.0.2",
"react-dom": "^16.5.2",
"react-loadable": "^5.5.0",
"react-redux": "^5.0.7",
"react-router": "^4.3.1",
"react-router-dom": "^4.3.1",
"react-scripts": "^1.1.5",
"react-transition-group": "^2.5.0",
"redux": "^4.0.0",
"redux-immutable": "^4.0.0",
"redux-thunk": "^2.3.0",
"resolve": "1.6.0",
"style-loader": "0.19.0",
"sw-precache-webpack-plugin": "0.11.4",
"url-loader": "0.6.2",
"webpack": "3.8.1",
"webpack-dev-server": ">=3.1.11",
"webpack-manifest-plugin": "1.3.2",
"whatwg-fetch": "2.0.3"
},
"scripts": {
"start": "PORT=3001 react-app-rewired start",
"build": "react-app-rewired build",
"test": "react-app-rewired test --env=jsdom"
"start": "PORT=3001 react-app-rewired start",
"build": "react-app-rewired build",
"test": "react-app-rewired test --env=jsdom"
},
"jest": {
"collectCoverageFrom": [
"src/**/*.{js,jsx,mjs}"
],
"setupFiles": [
"<rootDir>/config/polyfills.js"
],
"testMatch": [
"<rootDir>/src/**/__tests__/**/*.{js,jsx,mjs}",
"<rootDir>/src/**/?(*.)(spec|test).{js,jsx,mjs}"
],
"testEnvironment": "node",
"testURL": "http://localhost",
"transform": {
"^.+\\.(js|jsx|mjs)$": "<rootDir>/node_modules/babel-jest",
"^.+\\.css$": "<rootDir>/config/jest/cssTransform.js",
"^(?!.*\\.(js|jsx|mjs|css|json)$)": "<rootDir>/config/jest/fileTransform.js"
},
"transformIgnorePatterns": [
"[/\\\\]node_modules[/\\\\].+\\.(js|jsx|mjs)$"
],
"moduleNameMapper": {
"^react-native$": "react-native-web"
},
"moduleFileExtensions": [
"web.js",
"js",
"json",
"web.jsx",
"jsx",
"node",
"mjs"
]
"collectCoverageFrom": [
"src/**/*.{js,jsx,mjs}"
],
"setupFiles": [
"<rootDir>/config/polyfills.js"
],
"testMatch": [
"<rootDir>/src/**/__tests__/**/*.{js,jsx,mjs}",
"<rootDir>/src/**/?(*.)(spec|test).{js,jsx,mjs}"
],
"testEnvironment": "node",
"testURL": "http://localhost",
"transform": {
"^.+\\.(js|jsx|mjs)$": "<rootDir>/node_modules/babel-jest",
"^.+\\.css$": "<rootDir>/config/jest/cssTransform.js",
"^(?!.*\\.(js|jsx|mjs|css|json)$)": "<rootDir>/config/jest/fileTransform.js"
},
"transformIgnorePatterns": [
"[/\\\\]node_modules[/\\\\].+\\.(js|jsx|mjs)$"
],
"moduleNameMapper": {
"^react-native$": "react-native-web"
},
"moduleFileExtensions": [
"web.js",
"js",
"json",
"web.jsx",
"jsx",
"node",
"mjs"
]
},
"proxy": {
"/api": {
"target": "http://127.0.0.1:3000/",
"changeOrigin": true,
"pathRewrite": {
"^/api": ""
"/api": {
"target": "http://127.0.0.1:3000/",
"changeOrigin": true,
"pathRewrite": {
"^/api": ""
}
}
}
},
"babel": {
"presets": [
"react-app"
],
"plugins": [
"transform-decorators-legacy"
]
"presets": [
"react-app"
],
"plugins": [
"transform-decorators-legacy"
]
},
"eslintConfig": {
"extends": "react-app"
"extends": "react-app"
},
"devDependencies": {
"babel-plugin-transform-decorators-legacy": "^1.3.5"
"babel-plugin-transform-decorators-legacy": "^1.3.5"
}
}
53 changes: 38 additions & 15 deletions public/index.html
Original file line number Diff line number Diff line change
@@ -1,30 +1,53 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta id="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" name="viewport" />
<meta name="theme-color" content="#000000">
<link rel="manifest" href="%PUBLIC_URL%/manifest.json">
<link rel="shortcut icon" href="%PUBLIC_URL%/favicon.ico">
<link href="http://cdn.bootcss.com/highlight.js/8.0/styles/monokai_sublime.min.css" rel="stylesheet">
<meta charset="utf-8" />
<meta
id="viewport"
content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no"
name="viewport"
/>
<meta name="theme-color" content="#000000" />
<link rel="manifest" href="%PUBLIC_URL%/manifest.json" />
<link rel="shortcut icon" href="%PUBLIC_URL%/favicon.ico" />
<link
href="http://cdn.bootcss.com/highlight.js/8.0/styles/monokai_sublime.min.css"
rel="stylesheet"
/>
<!-- <link rel="stylesheet" href="http://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/styles/default.min.css"> -->
<title id="title">BiaoChenXuYing 的个人博客网站</title>
<meta name="baidu-site-verification" content="7XGPmF2RtW" />
<meta id="keywords" name="keywords" content="BiaoChenXuYing 的博客网站">
<meta id="description" name="description" content="BiaoChenXuYing 的博客网站。BiaoChenXuYing,目前是一名前端开发工程师,BiaoChenXuYing 公众号作者,致力于前端和后端开发、全栈程序员的成长之路。">
<meta id="keywords" name="keywords" content="BiaoChenXuYing 的博客网站" />
<meta
id="description"
name="description"
content="BiaoChenXuYing 的博客网站。BiaoChenXuYing,目前是一名前端开发工程师,BiaoChenXuYing 公众号作者,致力于前端和后端开发、全栈程序员的成长之路。"
/>
</head>
<body>
<div id="root">
<div id="root">
<!-- 首屏加载动画 -->
<div style="text-align: center; height: 300px; margin-top: 15%">
<img src="./img/loading.svg" width="250" alt="加载中...">
</div>
<img src="./img/loading.svg" width="250" alt="加载中..." />
</div>
</div>
<script>
// 设置移动端单位自适应,移动端通用的单位为 rem。
document.getElementsByTagName('html')[0].style.fontSize = window.screen.width / 7.5 + 'px';
// 如上:通过查询屏幕宽度,动态的设置 html 的 font-size 值,设计稿大多以 750*1334 设置的,通过上述换算后,在设计图上一张 150*150 px 的图,在 css 中对应的 rem 值则为:1.5*1.5 rem
// 设置移动端单位自适应,移动端通用的单位为 rem。
document.getElementsByTagName('html')[0].style.fontSize =
window.screen.width / 7.5 + 'px';
// 如上:通过查询屏幕宽度,动态的设置 html 的 font-size 值,设计稿大多以 750*1334 设置的,通过上述换算后,在设计图上一张 150*150 px 的图,在 css 中对应的 rem 值则为:1.5*1.5 rem
</script>

<script>
// 百度统计代码
var _hmt = _hmt || [];
(function() {
var hm = document.createElement('script');
hm.src = 'https://hm.baidu.com/hm.js?e75c184727a975aa58adf4acc4123de8';
var s = document.getElementsByTagName('script')[0];
s.parentNode.insertBefore(hm, s);
})();
</script>
<script src="./js/three.min.js"></script>
<script src="./js/wave.js"></script>
</body>
</html>
Loading

0 comments on commit a8138f9

Please sign in to comment.