diff --git a/.idea/deployment.xml b/.idea/deployment.xml
new file mode 100644
index 0000000000000000000000000000000000000000..3d900d939689a5691666878902723578225ade2a
--- /dev/null
+++ b/.idea/deployment.xml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/inspectionProfiles/Project_Default.xml b/.idea/inspectionProfiles/Project_Default.xml
new file mode 100644
index 0000000000000000000000000000000000000000..03d9549ea8e4ada36fb3ecbc30fef08175b7d728
--- /dev/null
+++ b/.idea/inspectionProfiles/Project_Default.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/misc.xml b/.idea/misc.xml
new file mode 100644
index 0000000000000000000000000000000000000000..28a804d8932aba40f168fd757a74cb718a955a1a
--- /dev/null
+++ b/.idea/misc.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/modules.xml b/.idea/modules.xml
new file mode 100644
index 0000000000000000000000000000000000000000..21391d8ca8925972d51eaed38ef8f34c73a0537c
--- /dev/null
+++ b/.idea/modules.xml
@@ -0,0 +1,8 @@
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/vcs.xml b/.idea/vcs.xml
new file mode 100644
index 0000000000000000000000000000000000000000..94a25f7f4cb416c083d265558da75d457237d671
--- /dev/null
+++ b/.idea/vcs.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/webServers.xml b/.idea/webServers.xml
new file mode 100644
index 0000000000000000000000000000000000000000..26626eecda2825e106169b92e38f529a94dd3cf6
--- /dev/null
+++ b/.idea/webServers.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/workspace.xml b/.idea/workspace.xml
new file mode 100644
index 0000000000000000000000000000000000000000..7e1fd50931172a3169d7412149819fec93d8ca31
--- /dev/null
+++ b/.idea/workspace.xml
@@ -0,0 +1,206 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 1665923387310
+
+
+ 1665923387310
+
+
+
+
+ 1665930867783
+
+
+
+ 1665930867784
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/yma16_program.iml b/.idea/yma16_program.iml
new file mode 100644
index 0000000000000000000000000000000000000000..24643cc37449b4bde54411a80b8ed61258225e34
--- /dev/null
+++ b/.idea/yma16_program.iml
@@ -0,0 +1,12 @@
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/miniprogram/app.js b/miniprogram/app.js
index f473f0db81867f1f4b73d4c14c058bb5979e476b..44d34f9a496a25dd47523e59bb7dba3e3353ec18 100644
--- a/miniprogram/app.js
+++ b/miniprogram/app.js
@@ -11,7 +11,7 @@ App({
* @type object[{name:'',adcode:''}]
*/
geoAdcodeMap:[],
- targetItem:{}
+ targetItem:{},
},
remoteConfig:{
baseUrl:'https://yongma16.xyz'
@@ -53,6 +53,7 @@ App({
this.setData({
globalData:{userInfo: res.userInfo,hasUserInfo: true},
})
+ wx.setStorageSync('currentUserInfo', res.userInfo)
}
})
diff --git a/miniprogram/app.wxss b/miniprogram/app.wxss
index 4e6a5f460f4817d02d9c56a2fd8cd5f402f1d4de..91f0cd088cb0be8aeca6384fc043b9b10f3dabf5 100644
--- a/miniprogram/app.wxss
+++ b/miniprogram/app.wxss
@@ -4,7 +4,7 @@
flex-direction: column;
align-items: center;
box-sizing: border-box;
- color: #fff;
+ color: rgb(255, 255, 255);
}
button {
diff --git a/miniprogram/components/base/blockInfo/blockInfo.wxml b/miniprogram/components/base/blockInfo/blockInfo.wxml
index 0856a35b5eedfbb0ea961d13c0f6f1a4607403b5..e7c0192664a8286c92230c926dd525fe979aaef2 100644
--- a/miniprogram/components/base/blockInfo/blockInfo.wxml
+++ b/miniprogram/components/base/blockInfo/blockInfo.wxml
@@ -24,4 +24,4 @@
->
+
diff --git a/miniprogram/components/base/blockInfo/blockInfo.wxss b/miniprogram/components/base/blockInfo/blockInfo.wxss
index 2d1796fa3c1118912d91a59f627c7c464161ba60..af5815d43b4abf762bceb7f289df8e8bbd2fc559 100644
--- a/miniprogram/components/base/blockInfo/blockInfo.wxss
+++ b/miniprogram/components/base/blockInfo/blockInfo.wxss
@@ -1,16 +1,16 @@
/* components/base/blockInfo/blockInfo.wxss */
.container-block{
- width: 100vw;
+ width: 100%;
margin-top: 30px;
- background: rgba(255,255,255,0.8);
- padding: 10px;
+ background: rgba(255,255,255,0);
+ padding: 30px 0;
text-align: center;
}
.total-container{
display: flex;
- width: 100vw;
+ width: 100%;
font-weight: bold;
}
.block{
@@ -24,6 +24,7 @@
}
.block-title{
font-weight: bold;
+ margin:20px 0 5px 0;
background: cornflowerblue;
}
.block-uni-title{
diff --git a/miniprogram/components/visualComponent/geoMap/geoMap.wxss b/miniprogram/components/visualComponent/geoMap/geoMap.wxss
index c34e9ca50601817be7f7e65c40e5bfa77e0dd593..5a34d33a59f7bd67404257a8927160952fed3477 100644
--- a/miniprogram/components/visualComponent/geoMap/geoMap.wxss
+++ b/miniprogram/components/visualComponent/geoMap/geoMap.wxss
@@ -5,5 +5,5 @@
margin-top: 50px;
width:100vw;
height:300px;
- background: rgba(255,255,255,0.8);
+ background: rgba(255,255,255,0);
}
diff --git a/miniprogram/components/visualComponent/lineChart/lineChart.js b/miniprogram/components/visualComponent/lineChart/lineChart.js
index bc8a498f138b8af8ac19a817b62abc4721987c74..ec69c767b40ea0fd156727bbb2b377b9d6c54d85 100644
--- a/miniprogram/components/visualComponent/lineChart/lineChart.js
+++ b/miniprogram/components/visualComponent/lineChart/lineChart.js
@@ -1,10 +1,10 @@
// components/visualComponent/lineChart/lineChart.js
import * as echarts from '../../../ec-canvas/ec-canvas/echarts';
-const app=getApp();
+const app = getApp();
function initChart(canvas, width, height, dpr) {
const geoAdcodeMap = [...app.globalData.geoAdcodeMap]
- const targetItem = {...app.globalData.hotData.targetItem};
+ const targetItem = { ...app.globalData.hotData.targetItem };
/**
* @type object data热力值 max最大值
*/
@@ -33,13 +33,14 @@ function initChart(canvas, width, height, dpr) {
devicePixelRatio: dpr
});
canvas.setChart(chart);
- const lineObj={
- labelArray:[],
- totalData:[],
- todayData:[]
+ const lineObj = {
+ labelArray: [],
+ totalData: [],
+ todayData: []
}
- hotObj.data.forEach(item=>{
- lineObj.labelArray.push(item.name)
+ hotObj.data.forEach(item => {
+ const name = item.name.toString().includes('黔南') ? '黔南' : item.name.toString().substring(0, 3);
+ lineObj.labelArray.push(name)
lineObj.totalData.push(item.totalConfirm)
lineObj.todayData.push(item.todayConfirm)
})
@@ -54,13 +55,13 @@ function initChart(canvas, width, height, dpr) {
},
legend: {
data: ['累计确诊', '新增确诊'],
-
+
},
toolbox: {
+ show: false,
orient: 'vertical',
left: 'right',
top: 'center',
- show: true,
feature: {
// dataView: { show: true, readOnly: false },
magicType: { show: true, type: ['line', 'bar'] },
@@ -72,13 +73,18 @@ function initChart(canvas, width, height, dpr) {
xAxis: [
{
type: 'category',
- // prettier-ignore
- data: lineObj.labelArray
+ data: lineObj.labelArray,
+ axisLabel: {
+ show: true,
+ formatter: function (value) {
+ return value.split("").join("\n");
+ }
+ }
}
],
yAxis: [
{
- type: 'value'
+ type: 'value',
}
],
series: [
diff --git a/miniprogram/components/visualComponent/lineChart/lineChart.wxss b/miniprogram/components/visualComponent/lineChart/lineChart.wxss
index 823ccd748da73fd9d74544edf4d1771b442aace4..a6df40a0fedfd97f4ccc66486f756b9166159d45 100644
--- a/miniprogram/components/visualComponent/lineChart/lineChart.wxss
+++ b/miniprogram/components/visualComponent/lineChart/lineChart.wxss
@@ -4,5 +4,5 @@
margin-top: 30px;
width: 100vw;
height: 350px;
- background: rgba(255,255,255,0.8);
+ background: rgba(255,255,255,0);
}
\ No newline at end of file
diff --git a/miniprogram/pages/blog/blog.js b/miniprogram/pages/blog/blog.js
index c11a05ae8c2b08359bb43d2799da00e75264e48e..c8fe6caa32657107db5c7486923465eb634905aa 100644
--- a/miniprogram/pages/blog/blog.js
+++ b/miniprogram/pages/blog/blog.js
@@ -101,7 +101,6 @@ Component({
* @param {*} title
*/
setArticleNode(articleStr,title){
- console.log('接受',articleStr,title)
const markdownText = app.towxml(articleStr,'markdown',{
theme:'light', //主题 dark 黑色,light白色,不填默认light
events:{ //为元素绑定的事件方法
@@ -119,6 +118,12 @@ Component({
currentTitle:title
})
},
+ clearArticleNode(){
+ this.setData({
+ article:null,
+ currentTitle:'加载中...'
+ })
+ },
onMyButtonTap: function(){
this.setData({
// 更新属性和数据的方法与更新页面数据的方法类似
diff --git a/miniprogram/pages/blog/blog.wxml b/miniprogram/pages/blog/blog.wxml
index ec79fe8b271dc52c423e5d48ac27a2ed48ba15f7..57c4256e80bfe2dde05e6ddbaa56791957a98f1a 100644
--- a/miniprogram/pages/blog/blog.wxml
+++ b/miniprogram/pages/blog/blog.wxml
@@ -1,12 +1,14 @@
+
+{{currentTitle}}
+
-
-{{currentTitle}}
+
+
-
diff --git a/miniprogram/pages/blog/blog.wxss b/miniprogram/pages/blog/blog.wxss
index 976e9a67691dc34454dd52a67cd2b72efb2220d4..f32f647c3114ba2f4ef920452a66a793142e8b90 100644
--- a/miniprogram/pages/blog/blog.wxss
+++ b/miniprogram/pages/blog/blog.wxss
@@ -2,9 +2,9 @@
.container-blog{
position: relative;
width: 100vw;
- height:100vh;
+ height:90vh;
background: rgba(255,255,255,0.8); /* fallback for old browsers */
- overflow: auto;
+ overflow: hidden;
}
.loading{
@@ -13,21 +13,29 @@
height: 100px;
perspective: 780px;
position: relative;
- top:25%;
+ top:20%;
left:50%;
- transform: translate(-50%,-25%);
+ transform: translate(-50%,-20%);
+}
+.blog-container-box{
+ width: 100vw;
+ height: calc(100vh - 110px);
+ overflow: auto;
}
.blog-container{
- margin-top:30px;
+ margin-top:100px;
width: 100vw;
- height: 100vh;
+ height: auto;
+ margin-bottom:10px;
}
.blog-title{
text-align: center;
font-weight: bold;
- background: rgb(114, 158, 240);
- position: absolute;
+ background: rgba(114, 158, 240);
+ color: #ffffff;
+ position: relative;
margin:0;
- padding:0;
+ padding: 10px;
width: 100%;
+ min-height: 20px;
}
\ No newline at end of file
diff --git a/miniprogram/pages/future/future.js b/miniprogram/pages/future/future.js
index df1a23a98adf44c11f821dd61473b366e8983031..da12ccd26fa85b2bead9acf7c2b3cb82bc7120ae 100644
--- a/miniprogram/pages/future/future.js
+++ b/miniprogram/pages/future/future.js
@@ -9,15 +9,40 @@ Component({
options: {
addGlobalClass: true,
},
+
+ // 属性定义
+ properties: {
+ // 用户信息
+ userInfo: {
+ type: Object,
+ value: ()=>{
+ return {
+
+ }
+ },
+ observer: function(newVal, oldVal) {
+ // 属性值变化时执行
+ console.log(newVal,oldVal,'change')
+ }
+ }
+ },
/**
*组件的初始数据
*/
data: {
- content: '子组件的content',
- btnType:'map',
- homeHeaderItem: '',
- isLoading: false,
- article: { 'key': 12 },
+ mode:'introduce',
+ article:{},
+ articleId:44,
+ baseUrl:'https://yongma16.xyz/api/',
+ path:'article/blog/',
+ currentUserInfo:{
+ nickName:'',
+ avatarUrl:''
+ },
+ aiConfig:{
+ avatarUrl:'https://yongma16.xyz/staticFile/common/img/aiTop.jpg',
+ bgUrl:'https://yongma16.xyz/staticFile/common/img/aiBg.jpg'
+ },
searchOpenAiText:'',
responseText:'',
// questions,answer,index
@@ -29,13 +54,11 @@ Component({
}],
currentIndex:0
}
- },
- observers: {
-
},
lifetimes: {
// 生命周期函数,可以为函数,或一个在 methods 段中定义的方法名
attached: function () {
+ this.getRemoteArticle(this.data.articleId)
if(wx.getStorageSync('openAiOptions')){
this.setData(
{
@@ -43,6 +66,16 @@ Component({
}
)
}
+
+ if(wx.getStorageSync('currentUserInfo')){
+ console.log('currentUserInfo',wx.getStorageSync('currentUserInfo'))
+ this.setData(
+ {
+ currentUserInfo:wx.getStorageSync('currentUserInfo')
+ }
+ )
+ }
+
},
moved: function () { },
detached: function () {
@@ -50,20 +83,52 @@ Component({
},
},
- // 生命周期函数,可以为函数,或一个在 methods 段中定义的方法名
- // attached: function () { }, // 此处 attached 的声明会被 lifetimes 字段中的声明覆盖
- // ready: function() { },
-
- pageLifetimes: {
- // 组件所在页面的生命周期函数
- show: function () {
- console.log('pageLifetimes')
- },
- hide: function () { },
- resize: function () { },
- },
-
methods: {
+ getRemoteArticle:function(id){
+ this.setData({
+ isLoading:true
+ })
+ const baseUrl=this.data.baseUrl
+ const path=this.data.path
+ const headers = {'Content-Type':'application/json;charset=UTF-8'}
+ const that=this
+ const params={
+ id:id
+ }
+ wx.request({
+ url: baseUrl+path,
+ headers:headers,
+ data:params,
+ method:'POST',
+ success: (res) => {
+ const data=res.data
+ const articleStr=data&&data.article&&data.article
+ const markdownText = app.towxml(articleStr,'markdown',{
+ theme:'light', //主题 dark 黑色,light白色,不填默认light
+ base: baseUrl+path,
+ events:{ //为元素绑定的事件方法
+ tap:e => {
+ console.log('tap',e);
+ },
+ change:e => {
+ console.log('todo',e);
+ }
+ }
+ });
+ that.setData({
+ isLoading:false,
+ article:markdownText
+ })
+ }
+ });
+ },
+ changeMode(e){
+ const {mode}=e.currentTarget.dataset
+ console.log(mode,'mode')
+ this.setData({
+ mode:mode
+ })
+ },
bindKeyInput(e) {
const {columnIndex}=e.currentTarget.dataset
console.log('this.data.chatObjConfig',this.data.chatObjConfig)
@@ -91,6 +156,7 @@ Component({
cancelColor: 'cancelColor',
title:'请输入!'
})
+ return
}
wx.showLoading({
title: '加载中',
@@ -138,117 +204,21 @@ Component({
thisBack.setData(
{
isLoading: false,
+ searchOpenAiText:'',
chatObjConfig:chatObjConfig
}
)
- setTimeout(function () {
- wx.hideLoading()
- }, 2000)
+ wx.hideLoading()
resolve(res)
},
fail: error => {
thisBack.setData({
isLoading: false
})
- setTimeout(function () {
- wx.hideLoading()
- }, 2000)
- reject(error)
+ wx.hideLoading()
}
});
})
- },
-
- clickHeadBtn(e){
- console.log(e)
- const {btnType}=e.currentTarget.dataset
- this.setData(
- {btnType:btnType}
- )
- },
- async initData() {
- await this.getGeoJson()
- await this.getOutBreakData()
- this.setData({
- isLoading: false
- })
- },
- getGeoJson() {
- if(app.globalData.geoJson){
- return new Promise(resolve=>{
- resolve()
- })
- }
- const path = '/common-api/mapApp/getGeoJson/'
- const headers = { 'Content-Type': 'application/json;charset=UTF-8' }
- return new Promise((resolve, reject) => {
- wx.request({
- url: baseUrl + path,
- headers: headers,
- method: 'GET',
- success: (res) => {
- app.globalData.geoJson = res.data.data
- const geoAdcodeMap = []
- app.globalData.geoJson.features.map(item => {
- const { properties } = item
- geoAdcodeMap.push({
- name: properties.name,
- adcode: properties.adcode
- })
- })
- app.globalData.geoAdcodeMap = [...geoAdcodeMap]
- resolve(res.data.data)
- },
- fail: error => {
- reject(error)
- }
- });
- })
- },
-
- getOutBreakData() {
- if(app.globalData.hotData){
- return new Promise(resolve=>{
- resolve()
- })
- }
- const path = '/common-api/mapApp/outBreak/'
- const headers = { 'Content-Type': 'application/json;charset=UTF-8' }
- return new Promise((resolve, reject) => {
- wx.request({
- url: baseUrl + path,
- headers: headers,
- method: 'GET',
- success: (res) => {
- app.globalData.hotData = res.data.data
- /**
- * @type {string} 贵州省 adcode
- */
- const targetAdcode = "520000"
- const targetItem = app.globalData.hotData.areaTree[0].children.find(item => { return item.adcode === targetAdcode })
- app.globalData.hotData.targetItem={...targetItem}
- resolve(res.data.data)
- },
- fail: error => {
- reject(error)
- }
- });
- })
- },
- onMyButtonTap: function () {
- this.setData({
- // 更新属性和数据的方法与更新页面数据的方法类似
- })
- },
- // 内部方法建议以下划线开头
- _myPrivateMethod: function () {
- // 这里将 data.A[0].B 设为 'myPrivateData'
- // this.setData({
- // 'A[0].B': 'myPrivateData'
- // })
- },
- _propertyChange: function (newVal, oldVal) {
-
}
}
})
\ No newline at end of file
diff --git a/miniprogram/pages/future/future.json b/miniprogram/pages/future/future.json
index 5ef701d32d6baca81741f374df17ed5fc29c6a09..d7b07c726bc6fdec0b10b3e2d24472753b109da5 100644
--- a/miniprogram/pages/future/future.json
+++ b/miniprogram/pages/future/future.json
@@ -2,6 +2,7 @@
"usingComponents": {
"geoMap":"/components/visualComponent/geoMap/geoMap",
"lineChart":"/components/visualComponent/lineChart/lineChart",
- "blockInfo":"/components/base/blockInfo/blockInfo"
+ "blockInfo":"/components/base/blockInfo/blockInfo",
+ "towxml":"/towxml/towxml"
}
-}
\ No newline at end of file
+}
diff --git a/miniprogram/pages/future/future.wxml b/miniprogram/pages/future/future.wxml
index a5840cfe6e587480768e2b8b3b12c452b8928ae1..1ff2ac95bdac3769ad4fad412e0c14411603c7d4 100644
--- a/miniprogram/pages/future/future.wxml
+++ b/miniprogram/pages/future/future.wxml
@@ -1,5 +1,5 @@
-
+
-
+
+
+
+
+
+
+
-
+
- 问:$
-
-
- 问:$ {{item.question}}
+
+
+ ({{currentUserInfo.nickName}}):
+
+
+
+ ({{currentUserInfo.nickName}}):$ {{item.question}}
+
-
- openai回答:$ {{item.answer}}
+
+
+
+ (openai):$ {{item.answer}}
+
+
-
-
+
+
diff --git a/miniprogram/pages/future/future.wxss b/miniprogram/pages/future/future.wxss
index 165269417a5e8d6f5000be529e8de738e554eac3..a85d065e0bbecf51ab36192e2e868d372ed87b00 100644
--- a/miniprogram/pages/future/future.wxss
+++ b/miniprogram/pages/future/future.wxss
@@ -1,8 +1,8 @@
/* pages/homeContent/homeContent.wxss */
-.container-future{
+.container-future {
position: relative;
width: 100vw;
- height:100vh;
+ height: 100vh;
background: linear-gradient(to right, rgba(1, 41, 116, 0.1) 1px, transparent 1px), linear-gradient(to bottom, rgba(1, 41, 116, 0.1) 1px, transparent 1px);
background-repeat: repeat;
background-size: 10px 10px;
@@ -11,112 +11,156 @@
box-sizing: border-box;
}
-.loading{
+.loading {
position: absolute;
width: 100px;
height: 100px;
perspective: 780px;
position: relative;
- top:25%;
- left:50%;
- transform: translate(-50%,-25%);
+ top: 25%;
+ left: 50%;
+ transform: translate(-50%, -25%);
}
-.container-box{
+
+.container-box {
position: relative;
width: 100%;
height: 100vh;
overflow: auto;
}
-.header-container{
+
+.header-container {
position: absolute;
- height:30px;
+ height: 30px;
width: 100%;
}
-.content-container{
- margin-top:30px;
+
+.content-container {
+ margin-top: 30px;
position: absolute;
- height:100vh;
+ height: 100vh;
width: 100%;
overflow: auto;
}
-.flex-container{
+
+.flex-container {
display: flex;
justify-content: center;
align-items: center;
line-height: 30px;
}
-.header-container{
+
+.header-container {
width: 100vw;
}
-.header-btn{
- color:#262626;
- margin:0;
- padding:0;
+
+.header-btn {
+ color: #262626;
+ margin: 0;
+ padding: 0;
}
-.title{
- color:#ffffff;
- flex:1;
+
+.title {
+ color: #ffffff;
+ flex: 1;
font-size: 12px;
line-height: 30px;
text-align: center;
background: rgb(252, 37, 8);
}
-button{
+
+button {
border-radius: 0;
outline: none;
font-weight: normal;
}
-.btn-default{
- color:#262626;
- flex:1;
- width:300px;
+
+.btn-default {
+ color: #262626;
+ flex: 1;
+ width: 300px;
text-align: center;
background-color: #ffffff;
}
-.actived{
+
+.actived {
color: #ffffff;
- flex:1;
+ flex: 1;
text-align: center;
background-color: rgb(8, 183, 252);
}
-.form-container-api{
+.form-container-api {
display: block;
- height:auto;
+ height: auto;
width: 100%;
}
-.form-request{
+.form-request {
display: block;
width: 100%;
- color:#07c160;
+ color: #07c160;
background-color: rgb(37, 0, 97);
+ line-height: 50px;
+ padding: 5px;
}
-.form-response{
+
+.form-response {
position: relative;
width: 100%;
margin-top: 10px;
display: block;
margin-bottom: 10px;
- color:#07c160;
- background-color: rgb(0, 72, 94);
+ color: #07c160;
+ background-color: rgb(0, 72, 94);
}
-.form-class-submit{
+
+.form-class-submit {
margin-top: 10px;
display: block;
width: 100%;
background-color: rgb(248, 70, 0);
}
-.form-submit-btn{
+.form-container-introduce {
+ position: relative;
width: 100%;
- display: block;
+ height: calc(100vh - 60px);
}
-.chat-container{
- margin-top:20px;
+.container-box-article{
+ position: relative;
width: 100%;
- height: 336px;
+ height: calc(100vh - 100px);
overflow: auto;
+}
+
+.chat-container {
+ margin-top: 10px;
+ width: 100%;
+ height: calc(100vh - 100px);
+ overflow: auto;
+ position: relative;
+}
+
+.user-image-box {
+ width: 200px;
+ height: 140px;
+ text-align: center;
+ align-items: center;
+}
+
+.user-image {
+ position: relative;
+ width: 15px;
+ height: 15px;
+ border-radius: 50%;
+}
+
+.ai-image {
+ position: relative;
+ width: 20px;
+ height: 20px;
+ border-radius: 50%;
}
\ No newline at end of file
diff --git a/miniprogram/pages/home/home.js b/miniprogram/pages/home/home.js
index 9824152f5c066f5db24f10a4e444a65a1469dce0..3fc4b427d5289665b68b74acf662ccbaccf15d9a 100644
--- a/miniprogram/pages/home/home.js
+++ b/miniprogram/pages/home/home.js
@@ -8,7 +8,7 @@ Page({
*/
data: {
title: 'header',
- userInfo: '',
+ userInfo: {},
content: '我是父组件的content',
footContent: "bottomContent",
headBackground: [
@@ -40,6 +40,15 @@ Page({
console.log('监听', newVal, oldVal)
}
},
+ /**
+ * 用户信息配置
+ */
+ setCurrentUserInfo(userInfo){
+ console.log('事件触发userInfo',userInfo)
+ this.setData({
+ userInfo:userInfo
+ })
+ },
/**
* 获取文章
*/
diff --git a/miniprogram/pages/home/home.wxml b/miniprogram/pages/home/home.wxml
index ac5a25bb3682cbdc7211b920dc19d2a75ff42122..a14f4695afb4ad5aa08ff1bcbb930699a89e4b74 100644
--- a/miniprogram/pages/home/home.wxml
+++ b/miniprogram/pages/home/home.wxml
@@ -6,9 +6,9 @@
diff --git a/miniprogram/pages/life/life.wxml b/miniprogram/pages/life/life.wxml
index dff69510366c5f7092e14d6f47f008005782d552..bc6f78d08007348db0b9ad50af8d6bc7a0a12901 100644
--- a/miniprogram/pages/life/life.wxml
+++ b/miniprogram/pages/life/life.wxml
@@ -8,26 +8,4 @@
-
-
-
diff --git a/miniprogram/pages/life/life.wxss b/miniprogram/pages/life/life.wxss
index 1e9abf276501b131befb6596b66fc75a55352f37..464c9fc439aa82f854cf2a846c1535942884faee 100644
--- a/miniprogram/pages/life/life.wxss
+++ b/miniprogram/pages/life/life.wxss
@@ -2,18 +2,24 @@
.container-life{
position: relative;
width: 100vw;
- height:100vh;
+ height:calc(100vh - 60px);
color:#ff00aa;
background: #fff; /* fallback for old browsers */
overflow: hidden;
animation-name:backdiv;
animation-duration: 6s;
animation-iteration-count: infinite;
+ box-sizing: border-box;
}
.container-box{
position: relative;
width: 100vw;
- height:100vh;
+ height: calc(100vh - 60px);
+ overflow: auto;
+}
+.blog-container{
+ width: 100vw;
+ overflow: auto;
}
.loading{