提交 58b971e1 作者: 宇宙超人

按需修改样式

上级 25740bd7
This source diff could not be displayed because it is too large. You can view the blob instead.
{
"prompt": "template"
"prompt" : "template"
}
......@@ -35,3 +35,15 @@
white-space: nowrap;
text-overflow: ellipsis;
}
.fontsize_28{
font-size: 28rpx;
font-weight: 500;
color: #333333;
}
.fontsize_24{
font-size: 24rpx;
font-weight: 400;
}
.align-center{
align-items: center;
}
......@@ -187,13 +187,22 @@ export function flyTo(
map: MapboxInstance,
center: [number, number] = DEFAULT_MAP_CENTER,
zoom: number = DEFAULT_MAP_ZOOM,
duration?: number,
) {
map.flyTo({
const flyOptions: any = {
center,
zoom,
speed: 0.2,
essential: true,
})
}
// 如果提供了时长,使用 duration 参数
if (duration !== undefined) {
flyOptions.duration = duration * 1000 // 转换为毫秒
} else {
flyOptions.speed = 0.2
}
map.flyTo(flyOptions)
}
/**
......
......@@ -39,13 +39,13 @@ export const defaultStyle: mapboxgl.Style = {
sprite: `${host}/api/sprites/drainage/sprite`,
glyphs: `${host}/api/fonts/{fontstack}/{range}.pbf`,
sources: {
'wms-img_w-source': {
'wms-cia_w-source': {
type: 'raster',
tiles: [buildTdtTileUrl('img', tk)],
tiles: [buildTdtTileUrl('cia', tk)],
tileSize: 256,
maxzoom: 18,
},
'wms-cia_w-source': {
'wms-img_w-source': {
type: 'raster',
tiles: [buildTdtTileUrl('cia', tk)],
tileSize: 256,
......@@ -58,20 +58,20 @@ export const defaultStyle: mapboxgl.Style = {
id: 'background',
type: 'background',
layout: { visibility: 'visible' },
paint: { 'background-color': '#FFFFFF' },
paint: { 'background-color': '#EFF3FA' },
},
// 默认图层 - 影像底图
// 默认图层 - 标注底图
{
id: 'wms-img_w-layer',
id: 'wms-cia_w-layer',
type: 'raster',
source: 'wms-img_w-source',
source: 'wms-cia_w-source',
layout: { visibility: 'visible' },
},
// 默认图层 - 标注底图
// 默认图层 - 影像底图
{
id: 'wms-cia_w-layer',
id: 'wms-img_w-layer',
type: 'raster',
source: 'wms-cia_w-source',
source: 'wms-img_w-source',
layout: { visibility: 'visible' },
},
// 天空图层
......
......@@ -100,7 +100,7 @@ export default {
if (this.map && this.map.remove) {
this.map.remove()
}
console.log(123123, merge(defaultStyle, options?.style))
// [107.570282, 19.474339],
// [115.629717, 34.466859],
......
......@@ -58,7 +58,7 @@
</view>
<text class="text-black">联系方式<text class="text-grey">(选填)</text> </text>
<input class="feedback-input" v-model="model.mobile" placeholder="请输入您的手机号" />
<input class="feedback-input" type="number" v-model="model.mobile" placeholder="请输入您的手机号" />
<view class="btn">
<fui-button
:disabled="!model.content || model.loading"
......
......@@ -44,7 +44,7 @@
<view class="codefun-mt-12 codefun-flex-col section_4">
<text class="codefun-self-start font text_11">郴州市财汇商务咨询有限公司</text>
<text class="codefun-self-stretch font_6 text_12">
州市财汇商务咨询有限公司自2022年成立以来,业务发展迅速,客户群体以政府及公共机构为主。服务涵盖:
州市财汇商务咨询有限公司自2022年成立以来,业务发展迅速,客户群体以政府及公共机构为主。服务涵盖:
</text>
<view class="codefun-flex-col codefun-self-stretch group_5">
<view class="codefun-flex-row group_6">
......@@ -513,6 +513,7 @@
font-family: SourceHanSansCN;
line-height: 24rpx;
color: #666666;
font-weight: 400;
}
.group_18 {
margin-top: 24rpx;
......@@ -566,8 +567,8 @@
.font_8 {
font-size: 28rpx;
font-family: SourceHanSansCN;
line-height: 26.34rpx;
color: #333333;
font-weight: 500;
}
}
.font {
......
......@@ -172,7 +172,7 @@
},
],
// 农机案例
// 品牌策划
machineryCases: [
{
id: 1,
......@@ -181,7 +181,7 @@
},
{
id: 2,
name: '绿鲜农场',
name: '山水有机',
image: '/static/images/codefun/8d11e3cbcb918502bb6582a24cddb930.png',
},
],
......@@ -378,7 +378,7 @@
@click="onMenuItemClick(item)"
>
<image class="image_7" :src="item.icon_url" />
<text class="font_4" :class="`text_${item.id + 2} mt-13`">{{ item.name }}</text>
<text class="fontsize_28" :class="`text_${item.id + 2} mt-13`">{{ item.name }}</text>
</view>
</view>
</view>
......@@ -476,6 +476,9 @@
>
<view
class="codefun-flex-col codefun-justify-start codefun-items-start codefun-self-stretch section_10"
:style="{
'background-image': `url(${product.image})`,
}"
>
<view
class="codefun-flex-col codefun-justify-start codefun-items-center text-wrapper_3"
......@@ -549,7 +552,7 @@
<view
class="codefun-flex-row codefun-justify-between codefun-items-center codefun-self-stretch group_14"
>
<text class="font_5">一站式解决农机问题</text>
<text class="font_5">品牌策划</text>
<!-- <text class="font_6 text_37" @click="onViewAllMachineryCases">全部案例</text> -->
</view>
<view class="codefun-flex-col codefun-self-stretch section_14">
......@@ -1188,7 +1191,7 @@
.section_10 {
padding: 20rpx 0 130rpx;
border-radius: 16rpx 16rpx 0rpx 0rpx;
background-image: url('/static/images/codefun/e1d1e83ba1f6592210e646c5b6ca5b53.png');
// background-image: url('/static/images/codefun/e1d1e83ba1f6592210e646c5b6ca5b53.png');
background-size: 100% 100%;
background-repeat: no-repeat;
}
......
......@@ -308,6 +308,7 @@
v-model="model.form.data.code"
backgroundColor="transparent"
borderColor="#DDDDDD"
type="number"
>
<template #left>
<view class="fui-left__icon mr-2">
......
......@@ -122,7 +122,7 @@
@click="toNewsDetail(news)"
>
<view class="flex flex-col justify-between" :style="news.posterUrl ? 'width: 68%' : 'width: 100%'">
<view class="ellipsis-multiline text-28 color-#333333">{{ news.title }}</view>
<view class="ellipsis-multiline fontsize_28 color-#333333">{{ news.title }}</view>
<view class="flex flex-row justify-between text-25 color-#686868">
<text>{{ dayjs(news.publishDate).format('YYYY年MM月DD日') }}</text>
<view class="mr-1 flex-center">
......@@ -132,7 +132,7 @@
<view v-show="!news.posterUrl" class="w-4%"></view>
</view>
</view>
<view v-show="news.posterUrl" class="w-30% h-120">
<view v-show="news.posterUrl" class="w-30% h-130">
<image class="w-full h-full border-rd" :src="news.posterUrl" />
</view>
</view>
......
......@@ -20,7 +20,7 @@
console.log('forecasts', forecasts)
// 逐 7 天预报数据
const _7DayForecastData = forecasts.map((item) => {
const _7DayForecastData = forecasts.map((item, index) => {
return {
minTem: item.tempMin,
maxTem: item.tempMax,
......@@ -28,9 +28,12 @@
textNight: item.textNight,
dayWeather: item.iconDay,
nightWeather: item.iconNight,
fxDate: item.fxDate,
...getDayLabelValue(index),
}
})
const _7DayForecastMaxTemValue = Math.max(..._7DayForecastData.map((item) => Number(item.maxTem)))
const _7DayForecastMinTemValue = Math.min(..._7DayForecastData.map((item) => Number(item.minTem)))
// 设置逐 7 天预报图表参数
Forecast7Chart.setOption({
......@@ -41,15 +44,14 @@
},
},
grid: {
top: '38%',
bottom: '3%',
left: '0%',
right: '0%',
top: '25%',
bottom: '10%',
left: '0',
right: '3%',
},
xAxis: [
{
xAxis: {
type: 'category',
data: [],
data: _7DayForecastData.map((item) => item.value),
axisLine: {
show: false,
},
......@@ -57,23 +59,9 @@
show: false,
},
axisLabel: {
interval: 0,
},
show: false, // 隐藏x轴标签
},
{
type: 'category',
data: [],
axisLine: {
show: false,
},
axisTick: {
show: false,
},
axisLabel: {
interval: 0,
},
},
],
yAxis: {
type: 'value',
splitLine: {
......@@ -85,59 +73,70 @@
},
series: [
{
label: {
show: true,
position: 'top',
formatter: '{c}°c',
},
name: '最高温度',
type: 'line',
data: _7DayForecastData.map((item) => item.maxTem),
smooth: true,
color: '#F79D80',
},
{
symbolSize: 6,
label: {
show: true,
position: 'bottom',
formatter: '{c}°c',
position: 'top',
formatter: '{c}°',
color: '#F79D80',
fontSize: 11,
},
},
{
name: '最低温度',
type: 'line',
data: _7DayForecastData.map((item) => item.minTem),
smooth: true,
color: '#1890FF',
color: '#52C41A',
symbolSize: 6,
label: {
show: true,
position: 'bottom',
formatter: '{c}°',
color: '#52C41A',
fontSize: 11,
},
},
{
name: '白天天气',
type: 'scatter',
data: _7DayForecastData.map((item, index) => {
const { label, value } = getDayLabelValue(index)
console.log('item', item,[index, Number(_7DayForecastMaxTemValue) + 3])
return {
value: [index, Number(_7DayForecastMaxTemValue) + 7, item.textDay],
value: [index, Number(_7DayForecastMaxTemValue) + 3],
symbol: `image://${getWeatherIcon(String(item.dayWeather))}`,
symbolSize: [24, 24],
symbolOffset: [0, -35],
symbolSize: [20, 20],
symbolOffset: [0, -12],
label: {
show: true,
position: 'top',
formatter: `${label}\n\n${value}\n\n{@[2]}`,
formatter: `${item.label}\n${item.value}\n${item.textDay}`,
fontSize: 11,
color: '#333',
fontWeight: 'bold',
lineHeight: 18,
},
}
}),
},
{
name: '天气描述',
type: 'scatter',
data: _7DayForecastData.map((item, index) => {
return {
value: [index, -7, item.textNight],
symbol: `image://${getWeatherIcon(String(item.nightWeather))}`,
symbolSize: [24, 24],
symbolOffset: [0, -20],
value: [index, Number(_7DayForecastMinTemValue) - 3],
symbolSize: 0,
label: {
show: true,
position: 'bottom',
formatter: '{@[2]}',
fontWeight: 'bold',
formatter: item.textDay,
fontSize: 10,
color: '#999',
},
}
}),
......@@ -153,7 +152,7 @@
<view class="rain-forecast mt-2rpx bg-#fff rd-1.5 shadow flex flex-col px-2">
<view class="flex items-center justify-between pt-3 px-2">
<view class="text-32 font-600">{{ model.days }} 天预报</view>
<view class="text-24">发布时间:{{ model.updateTime }}</view>
<!-- <view class="text-24">发布时间:{{ model.updateTime }}</view> -->
</view>
<scroll-view class="flex-1" scroll-x="true">
<Echarts @register="register7Forecast" class="w-1400 h-600" />
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论