diff --git a/src/assets/images/ui/btn_1@2x.png b/src/assets/images/ui/btn_1@2x.png new file mode 100644 index 0000000..3d829ab Binary files /dev/null and b/src/assets/images/ui/btn_1@2x.png differ diff --git a/src/assets/images/ui/img_man@2x.png b/src/assets/images/ui/img_man@2x.png new file mode 100644 index 0000000..0c62912 Binary files /dev/null and b/src/assets/images/ui/img_man@2x.png differ diff --git a/src/assets/images/ui/img_name_bg@2x.png b/src/assets/images/ui/img_name_bg@2x.png new file mode 100644 index 0000000..4302699 Binary files /dev/null and b/src/assets/images/ui/img_name_bg@2x.png differ diff --git a/src/assets/images/ui/img_tag_hz@2x.png b/src/assets/images/ui/img_tag_hz@2x.png new file mode 100644 index 0000000..6acded4 Binary files /dev/null and b/src/assets/images/ui/img_tag_hz@2x.png differ diff --git a/src/assets/images/ui/img_woman@2x.png b/src/assets/images/ui/img_woman@2x.png new file mode 100644 index 0000000..a792db0 Binary files /dev/null and b/src/assets/images/ui/img_woman@2x.png differ diff --git a/src/assets/images/ui/noData.png b/src/assets/images/ui/noData.png new file mode 100644 index 0000000..7eb120d Binary files /dev/null and b/src/assets/images/ui/noData.png differ diff --git a/src/assets/images/ui/tab1.png b/src/assets/images/ui/tab1.png new file mode 100644 index 0000000..651b0a0 Binary files /dev/null and b/src/assets/images/ui/tab1.png differ diff --git a/src/assets/images/ui/三角@2x.png b/src/assets/images/ui/三角@2x.png new file mode 100644 index 0000000..a723445 Binary files /dev/null and b/src/assets/images/ui/三角@2x.png differ diff --git a/src/components/ColorCell/index.vue b/src/components/ColorCell/index.vue index a899b2f..e6a9c67 100644 --- a/src/components/ColorCell/index.vue +++ b/src/components/ColorCell/index.vue @@ -10,6 +10,7 @@ > + diff --git a/src/store/getters.js b/src/store/getters.js index f090b86..0ab66ff 100644 --- a/src/store/getters.js +++ b/src/store/getters.js @@ -29,5 +29,6 @@ const getters = { mapParmas: (state) => state.xiaoqu.mapParmas, netWorkintroduce: (state) => state.xiaoqu.netWorkintroduce, panel: (state) => state.xiaoqu.panel, + houseItem: (state) => state.xiaoqu.houseItem, }; export default getters; diff --git a/src/store/modules/xiaoqu.js b/src/store/modules/xiaoqu.js index 60e30fd..c92ca03 100644 --- a/src/store/modules/xiaoqu.js +++ b/src/store/modules/xiaoqu.js @@ -10,6 +10,7 @@ const xiaoqu = { }, netWorkintroduce: {}, panel: {}, + houseItem: {}, }, mutations: { SET_PANEL: (state, boolean) => { @@ -17,6 +18,9 @@ const xiaoqu = { state.panel[key] = boolean[key]; } }, + SET_BUILDING_WIDTH: (state, data) => { + state.houseItem = data; + }, //参数变化 CHANGE_QUERY: (state, query) => { for (let key in query) { @@ -27,6 +31,10 @@ const xiaoqu = { state.panel.bottomPanel = true; return; } + { + state.panel.rightPanel = false; + } + if ( query.color || query.type || @@ -70,6 +78,7 @@ const xiaoqu = { isx: undefined, isj: undefined, }; + state.houseItem = {}; }, }, actions: { diff --git a/src/utils/myFuntion.js b/src/utils/myFuntion.js new file mode 100644 index 0000000..74b076c --- /dev/null +++ b/src/utils/myFuntion.js @@ -0,0 +1,56 @@ +import postcss from "../../postcss.config"; +import store from "@/store"; + +export function pxToVw(size) { + return ( + (100 * size) / postcss.plugins["postcss-px-to-viewport"].viewportWidth + + "vw" + ); +} + +export function handleColor(data) { + const leftColor = store.getters && store.getters.leftColor; + const rightTopColor = store.getters && store.getters.rightTopColor; + + if (checkType(data) == "array") { + data.map((item) => { + if (!item.color) { + item.leftColor = "#7b75ff"; + item.rightTopColor = "#7b75ff"; + return; + } + for (let key in leftColor) { + if (item.color == key) { + item.leftColor = leftColor[key]; + item.rightTopColor = rightTopColor[key]; + } + } + }); + return data; + } else if (checkType(data) == "object") { + if (!data.color) { + data.leftColor = "#7b75ff"; + data.rightTopColor = "#7b75ff"; + return; + } + for (let key in leftColor) { + if (data.color == key) { + data.leftColor = leftColor[key]; + data.rightTopColor = rightTopColor[key]; + } + } + return data; + } else { + return data; + } +} + +function checkType(value) { + if (Array.isArray(value)) { + return "array"; + } else if (value !== null && typeof value === "object") { + return "object"; + } else { + return "neither"; + } +} diff --git a/src/views/components/index.js b/src/views/components/index.js index 0d69539..0efa8e8 100644 --- a/src/views/components/index.js +++ b/src/views/components/index.js @@ -15,3 +15,4 @@ export { default as bottomList } from "./xiaoqu/bottomList.vue"; export { default as xiaoquRight } from "./xiaoqu/rightData/index.vue"; export { default as building } from "./xiaoqu/building.vue"; +export { default as house } from "./xiaoqu/house.vue"; diff --git a/src/views/components/xiaoqu/ColorCell/index.vue b/src/views/components/xiaoqu/ColorCell/index.vue index 4c533b4..706da74 100644 --- a/src/views/components/xiaoqu/ColorCell/index.vue +++ b/src/views/components/xiaoqu/ColorCell/index.vue @@ -1,9 +1,13 @@