Commit 426dd49b authored by 熊成伟's avatar 熊成伟

debug

parent 6095eb88
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="VcsDirectoryMappings">
<mapping directory="$PROJECT_DIR$" vcs="Git" />
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<project version="4"> <project version="4">
<component name="ChangeListManager"> <component name="ChangeListManager">
<list default="true" id="a6d092de-b4f8-454d-99f5-4dac3ce112e5" name="Default Changelist" comment="" /> <list default="true" id="a6d092de-b4f8-454d-99f5-4dac3ce112e5" name="Default Changelist" comment="">
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/config-overrides.js" beforeDir="false" afterPath="$PROJECT_DIR$/config-overrides.js" afterDir="false" />
<change beforePath="$PROJECT_DIR$/src/Pages/Work/Work.jsx" beforeDir="false" afterPath="$PROJECT_DIR$/src/Pages/Work/Work.jsx" afterDir="false" />
</list>
<ignored path="$PROJECT_DIR$/.tmp/" /> <ignored path="$PROJECT_DIR$/.tmp/" />
<ignored path="$PROJECT_DIR$/temp/" /> <ignored path="$PROJECT_DIR$/temp/" />
<ignored path="$PROJECT_DIR$/tmp/" /> <ignored path="$PROJECT_DIR$/tmp/" />
...@@ -16,10 +20,10 @@ ...@@ -16,10 +20,10 @@
<file pinned="false" current-in-tab="false"> <file pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/src/components/WorkCard/index.jsx"> <entry file="file://$PROJECT_DIR$/src/components/WorkCard/index.jsx">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="199"> <state relative-caret-position="175">
<caret line="21" column="19" selection-start-line="19" selection-start-column="16" selection-end-line="21" selection-end-column="19" /> <caret line="7" column="43" selection-start-line="7" selection-start-column="43" selection-end-line="7" selection-end-column="43" />
<folding> <folding>
<element signature="e#0#26#0" expanded="true" /> <element signature="e#0#39#0" expanded="true" />
</folding> </folding>
</state> </state>
</provider> </provider>
...@@ -28,71 +32,32 @@ ...@@ -28,71 +32,32 @@
<file pinned="false" current-in-tab="false"> <file pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/src/components/WorkCard/CardItem.jsx"> <entry file="file://$PROJECT_DIR$/src/components/WorkCard/CardItem.jsx">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="325"> <state relative-caret-position="284">
<caret line="13" selection-start-line="13" selection-end-line="13" /> <caret line="16" column="76" selection-start-line="16" selection-start-column="76" selection-end-line="16" selection-end-column="76" />
<folding>
<element signature="e#0#26#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
</file>
<file pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/src/components/WorkCard/index.less">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="150">
<caret line="9" column="7" selection-start-line="9" selection-start-column="2" selection-end-line="9" selection-end-column="7" />
</state>
</provider>
</entry>
</file>
<file pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/config-overrides.js">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="-1800">
<caret line="3" column="43" selection-start-line="3" selection-start-column="43" selection-end-line="3" selection-end-column="43" />
</state>
</provider>
</entry>
</file>
<file pinned="false" current-in-tab="true">
<entry file="file://$PROJECT_DIR$/src/index.js">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="225">
<caret line="9" selection-start-line="9" selection-end-line="9" />
<folding> <folding>
<element signature="e#0#26#0" expanded="true" /> <element signature="e#0#39#0" expanded="true" />
</folding> </folding>
</state> </state>
</provider> </provider>
</entry> </entry>
</file> </file>
<file pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/package.json">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="-51">
<caret line="11" column="18" selection-start-line="11" selection-start-column="11" selection-end-line="11" selection-end-column="18" />
</state>
</provider>
</entry>
</file>
<file pinned="false" current-in-tab="false"> <file pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/src/Pages/Work/Work.jsx"> <entry file="file://$PROJECT_DIR$/src/Pages/Work/Work.jsx">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="300"> <state relative-caret-position="73">
<caret line="12" column="21" selection-start-line="12" selection-start-column="21" selection-end-line="12" selection-end-column="21" /> <caret line="12" column="38" selection-start-line="12" selection-start-column="38" selection-end-line="12" selection-end-column="38" />
<folding> <folding>
<element signature="e#0#26#0" expanded="true" /> <element signature="e#0#39#0" expanded="true" />
</folding> </folding>
</state> </state>
</provider> </provider>
</entry> </entry>
</file> </file>
<file pinned="false" current-in-tab="false"> <file pinned="false" current-in-tab="true">
<entry file="file://$PROJECT_DIR$/src/components/TopSearch/index.jsx"> <entry file="file://$PROJECT_DIR$/src/components/TopSearch/index.jsx">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="250"> <state relative-caret-position="375">
<caret line="10" column="47" selection-start-line="10" selection-start-column="47" selection-end-line="10" selection-end-column="47" /> <caret line="15" column="38" selection-start-line="15" selection-start-column="29" selection-end-line="15" selection-end-column="38" />
<folding> <folding>
<element signature="e#0#26#0" expanded="true" /> <element signature="e#0#26#0" expanded="true" />
</folding> </folding>
...@@ -101,19 +66,19 @@ ...@@ -101,19 +66,19 @@
</entry> </entry>
</file> </file>
<file pinned="false" current-in-tab="false"> <file pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/src/components/TopSearch/index.less"> <entry file="file://$PROJECT_DIR$/src/components/WorkCard/index.less">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="250"> <state relative-caret-position="720">
<caret line="10" column="18" selection-start-line="10" selection-start-column="1" selection-end-line="10" selection-end-column="18" /> <caret line="49" column="21" selection-start-line="49" selection-start-column="1" selection-end-line="49" selection-end-column="21" />
</state> </state>
</provider> </provider>
</entry> </entry>
</file> </file>
<file pinned="false" current-in-tab="false"> <file pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/src/index.css"> <entry file="file://$PROJECT_DIR$/src/components/TopNotice/index.less">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="225"> <state relative-caret-position="200">
<caret line="9" selection-start-line="9" selection-end-line="9" /> <caret line="8" column="21" lean-forward="true" selection-start-line="8" selection-start-column="21" selection-end-line="8" selection-end-column="21" />
</state> </state>
</provider> </provider>
</entry> </entry>
...@@ -133,15 +98,24 @@ ...@@ -133,15 +98,24 @@
<find>create-react-app</find> <find>create-react-app</find>
<find>siz</find> <find>siz</find>
<find>favicon</find> <find>favicon</find>
<find>props</find>
<find>card-box</find> <find>card-box</find>
<find>autoprefixer</find> <find>autoprefixer</find>
<find>override</find> <find>override</find>
<find>px</find>
<find>fileLoaderMatcher</find>
<find>props</find>
<find>iconAdd</find>
<find>addClick</find>
</findStrings> </findStrings>
<replaceStrings> <replaceStrings>
<replace>this.props</replace> <replace>this.props</replace>
<replace>props</replace>
<replace>addCommon</replace>
</replaceStrings> </replaceStrings>
</component> </component>
<component name="Git.Settings">
<option name="RECENT_GIT_ROOT_PATH" value="$PROJECT_DIR$" />
</component>
<component name="IdeDocumentHistory"> <component name="IdeDocumentHistory">
<option name="CHANGED_PATHS"> <option name="CHANGED_PATHS">
<list> <list>
...@@ -153,7 +127,6 @@ ...@@ -153,7 +127,6 @@
<option value="$PROJECT_DIR$/src/components/TodoCard/index.less" /> <option value="$PROJECT_DIR$/src/components/TodoCard/index.less" />
<option value="$PROJECT_DIR$/src/Pages/Notice/Notice.jsx" /> <option value="$PROJECT_DIR$/src/Pages/Notice/Notice.jsx" />
<option value="$PROJECT_DIR$/src/components/TopNotice/index.jsx" /> <option value="$PROJECT_DIR$/src/components/TopNotice/index.jsx" />
<option value="$PROJECT_DIR$/src/components/TopNotice/index.less" />
<option value="$PROJECT_DIR$/src/router.js" /> <option value="$PROJECT_DIR$/src/router.js" />
<option value="$PROJECT_DIR$/src/components/TodoCard/index.jsx" /> <option value="$PROJECT_DIR$/src/components/TodoCard/index.jsx" />
<option value="$PROJECT_DIR$/src/components/TopTabs/index.less" /> <option value="$PROJECT_DIR$/src/components/TopTabs/index.less" />
...@@ -166,13 +139,14 @@ ...@@ -166,13 +139,14 @@
<option value="$PROJECT_DIR$/src/layout/Footer.jsx" /> <option value="$PROJECT_DIR$/src/layout/Footer.jsx" />
<option value="$PROJECT_DIR$/src/Pages/Communicate/Communicate.jsx" /> <option value="$PROJECT_DIR$/src/Pages/Communicate/Communicate.jsx" />
<option value="$PROJECT_DIR$/src/components/TopSearch/index.less" /> <option value="$PROJECT_DIR$/src/components/TopSearch/index.less" />
<option value="$PROJECT_DIR$/src/components/TopSearch/index.jsx" /> <option value="$PROJECT_DIR$/src/index.js" />
<option value="$PROJECT_DIR$/src/Pages/Work/Work.jsx" /> <option value="$PROJECT_DIR$/config-overrides.js" />
<option value="$PROJECT_DIR$/src/components/WorkCard/CardItem.jsx" /> <option value="$PROJECT_DIR$/src/components/TopNotice/index.less" />
<option value="$PROJECT_DIR$/src/components/WorkCard/index.less" /> <option value="$PROJECT_DIR$/src/components/WorkCard/index.less" />
<option value="$PROJECT_DIR$/src/components/WorkCard/CardItem.jsx" />
<option value="$PROJECT_DIR$/src/components/WorkCard/index.jsx" /> <option value="$PROJECT_DIR$/src/components/WorkCard/index.jsx" />
<option value="$PROJECT_DIR$/config-overrides.js" /> <option value="$PROJECT_DIR$/src/Pages/Work/Work.jsx" />
<option value="$PROJECT_DIR$/src/index.js" /> <option value="$PROJECT_DIR$/src/components/TopSearch/index.jsx" />
</list> </list>
</option> </option>
</component> </component>
...@@ -182,6 +156,9 @@ ...@@ -182,6 +156,9 @@
<option name="width" value="681" /> <option name="width" value="681" />
<option name="height" value="768" /> <option name="height" value="768" />
</component> </component>
<component name="ProjectLevelVcsManager" settingsEditedManually="true">
<ConfirmationsSetting value="1" id="添加" />
</component>
<component name="ProjectView"> <component name="ProjectView">
<navigator proportions="" version="1"> <navigator proportions="" version="1">
<foldersAlwaysOnTop value="true" /> <foldersAlwaysOnTop value="true" />
...@@ -211,6 +188,13 @@ ...@@ -211,6 +188,13 @@
<item name="src" type="462c0819:PsiDirectoryNode" /> <item name="src" type="462c0819:PsiDirectoryNode" />
<item name="components" type="462c0819:PsiDirectoryNode" /> <item name="components" type="462c0819:PsiDirectoryNode" />
</path> </path>
<path>
<item name="create-react-app" type="b2602c69:ProjectViewProjectNode" />
<item name="create-react-app" type="462c0819:PsiDirectoryNode" />
<item name="src" type="462c0819:PsiDirectoryNode" />
<item name="components" type="462c0819:PsiDirectoryNode" />
<item name="TopNotice" type="462c0819:PsiDirectoryNode" />
</path>
<path> <path>
<item name="create-react-app" type="b2602c69:ProjectViewProjectNode" /> <item name="create-react-app" type="b2602c69:ProjectViewProjectNode" />
<item name="create-react-app" type="462c0819:PsiDirectoryNode" /> <item name="create-react-app" type="462c0819:PsiDirectoryNode" />
...@@ -218,6 +202,13 @@ ...@@ -218,6 +202,13 @@
<item name="components" type="462c0819:PsiDirectoryNode" /> <item name="components" type="462c0819:PsiDirectoryNode" />
<item name="TopSearch" type="462c0819:PsiDirectoryNode" /> <item name="TopSearch" type="462c0819:PsiDirectoryNode" />
</path> </path>
<path>
<item name="create-react-app" type="b2602c69:ProjectViewProjectNode" />
<item name="create-react-app" type="462c0819:PsiDirectoryNode" />
<item name="src" type="462c0819:PsiDirectoryNode" />
<item name="components" type="462c0819:PsiDirectoryNode" />
<item name="WorkCard" type="462c0819:PsiDirectoryNode" />
</path>
<path> <path>
<item name="create-react-app" type="b2602c69:ProjectViewProjectNode" /> <item name="create-react-app" type="b2602c69:ProjectViewProjectNode" />
<item name="create-react-app" type="462c0819:PsiDirectoryNode" /> <item name="create-react-app" type="462c0819:PsiDirectoryNode" />
...@@ -281,15 +272,16 @@ ...@@ -281,15 +272,16 @@
<option name="number" value="Default" /> <option name="number" value="Default" />
<option name="presentableId" value="Default" /> <option name="presentableId" value="Default" />
<updated>1591238943411</updated> <updated>1591238943411</updated>
<workItem from="1591238945654" duration="23971000" /> <workItem from="1591238945654" duration="32617000" />
</task> </task>
<servers /> <servers />
</component> </component>
<component name="TimeTrackingManager"> <component name="TimeTrackingManager">
<option name="totallyTimeSpent" value="23971000" /> <option name="totallyTimeSpent" value="32617000" />
</component> </component>
<component name="ToolWindowManager"> <component name="ToolWindowManager">
<frame x="-8" y="-8" width="1382" height="784" extended-state="6" /> <frame x="-8" y="-8" width="1382" height="784" extended-state="6" />
<editor active="true" />
<layout> <layout>
<window_info id="npm" side_tool="true" /> <window_info id="npm" side_tool="true" />
<window_info id="Favorites" side_tool="true" /> <window_info id="Favorites" side_tool="true" />
...@@ -366,13 +358,6 @@ ...@@ -366,13 +358,6 @@
</state> </state>
</provider> </provider>
</entry> </entry>
<entry file="file://$PROJECT_DIR$/src/components/TopNotice/index.less">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="25">
<caret line="1" column="14" lean-forward="true" selection-start-line="1" selection-start-column="14" selection-end-line="1" selection-end-column="14" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/components/TopNotice/index.jsx"> <entry file="file://$PROJECT_DIR$/src/components/TopNotice/index.jsx">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="225"> <state relative-caret-position="225">
...@@ -474,88 +459,106 @@ ...@@ -474,88 +459,106 @@
</state> </state>
</provider> </provider>
</entry> </entry>
<entry file="file://$PROJECT_DIR$/src/components/TopSearch/index.less"> <entry file="file://$PROJECT_DIR$/src/Pages/Communicate/Communicate.jsx">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="250"> <state relative-caret-position="50">
<caret line="10" column="18" selection-start-line="10" selection-start-column="1" selection-end-line="10" selection-end-column="18" /> <caret line="2" column="50" selection-start-line="2" selection-start-column="50" selection-end-line="2" selection-end-column="50" />
<folding>
<element signature="e#0#39#0" expanded="true" />
</folding>
</state> </state>
</provider> </provider>
</entry> </entry>
<entry file="file://$PROJECT_DIR$/src/components/TopSearch/index.jsx"> <entry file="file://$PROJECT_DIR$/build/static/css/main.653da357.css">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="250"> <state>
<caret line="10" column="47" selection-start-line="10" selection-start-column="47" selection-end-line="10" selection-end-column="47" /> <caret column="313" selection-start-column="311" selection-end-column="313" />
<folding>
<element signature="e#0#26#0" expanded="true" />
</folding>
</state> </state>
</provider> </provider>
</entry> </entry>
<entry file="file://$PROJECT_DIR$/src/Pages/Communicate/Communicate.jsx"> <entry file="file://$PROJECT_DIR$/package.json">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="50"> <state relative-caret-position="200">
<caret line="2" column="50" selection-start-line="2" selection-start-column="50" selection-end-line="2" selection-end-column="50" /> <caret line="8" column="12" selection-start-line="8" selection-start-column="5" selection-end-line="8" selection-end-column="12" />
<folding>
<element signature="e#0#39#0" expanded="true" />
</folding>
</state> </state>
</provider> </provider>
</entry> </entry>
<entry file="file://$PROJECT_DIR$/src/Pages/Work/Work.jsx"> <entry file="file://$PROJECT_DIR$/src/index.js">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="300"> <state relative-caret-position="225">
<caret line="12" column="21" selection-start-line="12" selection-start-column="21" selection-end-line="12" selection-end-column="21" /> <caret line="9" selection-start-line="9" selection-end-line="9" />
<folding> <folding>
<element signature="e#0#26#0" expanded="true" /> <element signature="e#0#26#0" expanded="true" />
</folding> </folding>
</state> </state>
</provider> </provider>
</entry> </entry>
<entry file="file://$PROJECT_DIR$/src/components/WorkCard/index.jsx"> <entry file="file://$PROJECT_DIR$/config-overrides.js">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="199"> <state relative-caret-position="50">
<caret line="21" column="19" selection-start-line="19" selection-start-column="16" selection-end-line="21" selection-end-column="19" /> <caret line="20" column="24" selection-start-line="20" selection-start-column="24" selection-end-line="20" selection-end-column="24" />
<folding> <folding>
<element signature="e#0#26#0" expanded="true" /> <element signature="e#526#1590#0" />
<element signature="e#1658#2677#0" />
</folding> </folding>
</state> </state>
</provider> </provider>
</entry> </entry>
<entry file="file://$PROJECT_DIR$/src/components/WorkCard/CardItem.jsx"> <entry file="file://$PROJECT_DIR$/src/components/TopSearch/index.less">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="325"> <state relative-caret-position="250">
<caret line="13" selection-start-line="13" selection-end-line="13" /> <caret line="10" column="18" selection-start-line="10" selection-start-column="1" selection-end-line="10" selection-end-column="18" />
<folding>
<element signature="e#0#26#0" expanded="true" />
</folding>
</state> </state>
</provider> </provider>
</entry> </entry>
<entry file="file://$PROJECT_DIR$/src/components/WorkCard/index.less"> <entry file="file://$PROJECT_DIR$/src/components/WorkCard/index.less">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="150"> <state relative-caret-position="720">
<caret line="9" column="7" selection-start-line="9" selection-start-column="2" selection-end-line="9" selection-end-column="7" /> <caret line="49" column="21" selection-start-line="49" selection-start-column="1" selection-end-line="49" selection-end-column="21" />
</state> </state>
</provider> </provider>
</entry> </entry>
<entry file="file://$PROJECT_DIR$/package.json"> <entry file="file://$PROJECT_DIR$/src/components/TopNotice/index.less">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="-51"> <state relative-caret-position="200">
<caret line="11" column="18" selection-start-line="11" selection-start-column="11" selection-end-line="11" selection-end-column="18" /> <caret line="8" column="21" lean-forward="true" selection-start-line="8" selection-start-column="21" selection-end-line="8" selection-end-column="21" />
</state> </state>
</provider> </provider>
</entry> </entry>
<entry file="file://$PROJECT_DIR$/config-overrides.js"> <entry file="file://$PROJECT_DIR$/src/components/WorkCard/index.jsx">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="-1800"> <state relative-caret-position="175">
<caret line="3" column="43" selection-start-line="3" selection-start-column="43" selection-end-line="3" selection-end-column="43" /> <caret line="7" column="43" selection-start-line="7" selection-start-column="43" selection-end-line="7" selection-end-column="43" />
<folding>
<element signature="e#0#39#0" expanded="true" />
</folding>
</state> </state>
</provider> </provider>
</entry> </entry>
<entry file="file://$PROJECT_DIR$/src/index.js"> <entry file="file://$PROJECT_DIR$/src/Pages/Work/Work.jsx">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="225"> <state relative-caret-position="73">
<caret line="9" selection-start-line="9" selection-end-line="9" /> <caret line="12" column="38" selection-start-line="12" selection-start-column="38" selection-end-line="12" selection-end-column="38" />
<folding>
<element signature="e#0#39#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/components/WorkCard/CardItem.jsx">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="284">
<caret line="16" column="76" selection-start-line="16" selection-start-column="76" selection-end-line="16" selection-end-column="76" />
<folding>
<element signature="e#0#39#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/components/TopSearch/index.jsx">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="375">
<caret line="15" column="38" selection-start-line="15" selection-start-column="29" selection-end-line="15" selection-end-column="38" />
<folding> <folding>
<element signature="e#0#26#0" expanded="true" /> <element signature="e#0#26#0" expanded="true" />
</folding> </folding>
......
const { injectBabelPlugin, getLoader } = require('react-app-rewired'); const { injectBabelPlugin, getLoader } = require('react-app-rewired');
const {override} = require("customize-cra")
const path = require("path")
const rewirePostcss = require('react-app-rewire-postcss');
const px2rem = require('postcss-px2rem') const px2rem = require('postcss-px2rem')
const fileLoaderMatcher = function (rule) { const fileLoaderMatcher = function (rule) {
return rule.loader && rule.loader.indexOf(`file-loader`) != -1; return rule.loader && rule.loader.indexOf(`file-loader`) != -1;
} }
...@@ -13,6 +17,15 @@ module.exports = function override(config, env) { ...@@ -13,6 +17,15 @@ module.exports = function override(config, env) {
style: true, // use less for customized theme style: true, // use less for customized theme
}], config); }], config);
config = rewirePostcss(config,{
plugins: () => [
px2rem({
remUnit: 37.5,
exclude:/node-modules/
})
],
});
// customize theme // customize theme
config.module.rules[1].oneOf.unshift( config.module.rules[1].oneOf.unshift(
{ {
...@@ -28,10 +41,6 @@ module.exports = function override(config, env) { ...@@ -28,10 +41,6 @@ module.exports = function override(config, env) {
ident: 'postcss', ident: 'postcss',
plugins: () => [ plugins: () => [
require('postcss-flexbugs-fixes'), require('postcss-flexbugs-fixes'),
px2rem({
remUnit: 37.5,
exclude: /node-modules/
}),
autoprefixer({ autoprefixer({
browsers: [ browsers: [
'>1%', '>1%',
......
.search-notice-box{ .search-notice-box{
width: 100%; width: 100%;
height: 43.5px; height: 43.5px;
margin-bottom: 2px; margin-bottom: 1px;
display: flex; display: flex;
align-items: center; align-items: center;
} }
......
...@@ -3,12 +3,17 @@ import {SearchBar, Icon} from 'antd-mobile' ...@@ -3,12 +3,17 @@ import {SearchBar, Icon} from 'antd-mobile'
import './index.less' import './index.less'
const Index = () => { const Index = (props) => {
const topSearch = (val) => {
const input = document.getElementsByClassName("top-single-search").value;
console.log(val)
// props.onSearch(val)
}
return ( return (
<div className="search-box"> <div className="search-box">
<Icon type="search" size="xs" className="search-svg"/> <Icon type="search" size="xs" className="search-svg"/>
{/*<SearchBar/>*/} {/*<SearchBar/>*/}
<input className="top-single-search" placeholder="请输入关键字搜索" /> <input onChange={topSearch} className="top-single-search" placeholder="请输入关键字搜索" />
</div> </div>
); );
}; };
......
import React from 'react'; import React, {Component} from 'react';
import './index.less' import './index.less'
const CardItem = (peops) => { class CardItem extends Component {
return ( state = {
<div className="card-item"> addStatus: false
<div className="card-item-content"> }
<div className="card-item-content-img"> componentWillReceiveProps(nextProps, nextContext) {
<img src={peops.data.icon} style={{ width: 35, height: 35 }} alt="" /> if (this.props.addStatus !== nextProps.addStatus) {
</div> this.setState({ addStatus: this.props.addStatus });
<div className="card-item-content-title"> }
{peops.data.text} }
</div>
render() {
const {data, addCommon} = this.props;
return (
<div className="card-content" onClick={() => data.iconAdd ? addCommon() : null }>
{data.text && (
<div>
<div className="card-content-img">
<img src={data.icon} className="card-content-img-svg" alt="" />
</div>
<div className="card-content-title">
{data.text}
</div>
</div>
)}
</div> </div>
</div> );
); }
}; }
export default CardItem; export default CardItem;
import React from 'react'; import React, {Component} from 'react';
import {Grid} from 'antd-mobile' import {Grid} from 'antd-mobile'
import './index.less' import './index.less'
import CardItem from './CardItem' import CardItem from './CardItem'
const data = Array.from(new Array(7)).map((_val, i) => ({ class Index extends Component {
icon: 'https://gw.alipayobjects.com/zos/rmsportal/nywPmnTAvTmLusPxHPSu.png', render() {
text: `name${i}`, const {title, type, addStatus, addCommon} = this.props
})); const emptyIcon = type === 'edit' ? {
text: '添加常用', icon: '', iconAdd: true
const Index = () => { } : {};
const empty = data.length % 3;
empty > 0 && data.push({}, {})
return ( //测试数据
<div> const data = Array.from(new Array(7)).map((_val, i) => ({
<div className="work-card-title"> icon: 'https://gw.alipayobjects.com/zos/rmsportal/nywPmnTAvTmLusPxHPSu.png',
11111 text: `name${i}`,
</div> }));
<div className="work-card-body"> const empty = data.length % 3;
{data.map(item => ( empty === 0 && data.push(emptyIcon, {}, {});
<CardItem data={item}/> empty === 1 && data.push(emptyIcon, {});
))} empty === 2 && data.push(emptyIcon);
return (
<div>
<div className="work-card-title">
{title}
</div>
<div className="work-card-body">
{data.map((item, index) => (
<CardItem
key={index}
data={item}
addStatus={addStatus}
addCommon={addCommon}
/>
))}
</div>
</div> </div>
{/*<Grid*/} );
{/*data={data}*/} }
{/*columnNum={3}*/} }
{/*renderItem={dataItem => (*/}
{/*<div style={{ padding: '12.5px' }}>*/}
{/*<img src={dataItem.icon} style={{ width: 35, height: 35 }} alt="" />*/}
{/*<div style={{ color: '#323232', fontSize: 13, marginTop: 18 }}>*/}
{/*收文管理*/}
{/*</div>*/}
{/*</div>*/}
{/*)}*/}
{/*/>*/}
</div>
);
};
export default Index; export default Index;
...@@ -2,25 +2,54 @@ ...@@ -2,25 +2,54 @@
display:flex; display:flex;
flex-direction: row; flex-direction: row;
flex-wrap: wrap; flex-wrap: wrap;
justify-content: space-between; //justify-content: center;
align-items: center; align-items: center;
//background: #ffffff;
} }
.work-card-title{
.card-item{ line-height: 43px;
width: 33.33%; border-radius: 6px 6px 0 0;
position: relative; padding-left: 20px;
background: #ffffff;
margin-bottom: 1px;
color: rgba(50, 50, 50, 0.6);
} }
.card-item-content{
padding: 26px 0; .card-content{
width: 114px;
height: 114px;
display: flex; display: flex;
flex-direction: column;
align-items: center; align-items: center;
justify-content: center; justify-content: center;
flex-direction: column; background: #ffffff;
border: 1px salmon solid; margin-bottom: 1px;
//border: 1px solid rgba(38, 104, 255, 0.1);
} }
.card-item-content-img{ .work-card-body > .card-content:nth-child(3n + 2){
margin-bottom: 14px; margin-left: 1px;
}
.work-card-body > .card-content:nth-child(3n + 3){
margin-left: 1px;
}
.work-card-body > .card-content:last-child{
border-radius: 0 0 6px 0;
}
.work-card-body > .card-content:nth-last-child(3){
border-radius: 0 0 0 6px;
}
.card-content:active{
background: yellow;
} }
.card-item-content-title{
.card-content-img{
width: 35px;
height: 35px;
margin-bottom: 14px;
}
.card-content-img-svg{
width: 35px;
height: 35px;
}
.card-content-title{
} }
import React from 'react'; import React, {Component} from 'react';
import {WhiteSpace} from "antd-mobile"; import {WhiteSpace} from "antd-mobile";
import TopSearch from '../../components/TopSearch' import TopSearch from '../../components/TopSearch'
import WorkCard from '../../components/WorkCard' import WorkCard from '../../components/WorkCard'
const Work = () => { class Work extends Component {
return ( state = {
<div> addStatus: false
<WhiteSpace/> };
<TopSearch/> commonEdit = () => {
<WhiteSpace/> const {addStatus} = this.state;
<WorkCard/> this.setState({addStatus: !addStatus})
</div> };
); workSearch = (val) => {
}; console.log(val.target)
}
render() {
const {addStatus} = this.props
return (
<div>
<WhiteSpace/>
<TopSearch onSearch={this.workSearch}/>
<WhiteSpace/>
<WorkCard
type="edit"
title="常用板块"
addCommon={this.commonEdit}
addStatus={addStatus}
/>
<WhiteSpace/>
<WorkCard
title="事物管理"
addCommon={this.commonEdit}
addStatus={addStatus}
/>
</div>
);
}
}
export default Work; export default Work;
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