提交 c1528cff authored 作者: yanpeng's avatar yanpeng

resolve merge confict

...@@ -19,6 +19,7 @@ ...@@ -19,6 +19,7 @@
"echarts-wordcloud": "^2.1.0", "echarts-wordcloud": "^2.1.0",
"element-plus": "^2.4.4", "element-plus": "^2.4.4",
"highlight.js": "^11.11.1", "highlight.js": "^11.11.1",
"json5": "^2.2.3",
"markdown-it": "^14.1.0", "markdown-it": "^14.1.0",
"vue": "^3.4.0", "vue": "^3.4.0",
"vue-router": "^4.2.5" "vue-router": "^4.2.5"
...@@ -2899,6 +2900,7 @@ ...@@ -2899,6 +2900,7 @@
"version": "3.1.0", "version": "3.1.0",
"resolved": "https://registry.npmmirror.com/echarts-liquidfill/-/echarts-liquidfill-3.1.0.tgz", "resolved": "https://registry.npmmirror.com/echarts-liquidfill/-/echarts-liquidfill-3.1.0.tgz",
"integrity": "sha512-5Dlqs/jTsdTUAsd+K5LPLLTgrbbNORUSBQyk8PSy1Mg2zgHDWm83FmvA4s0ooNepCJojFYRITTQ4GU1UUSKYLw==", "integrity": "sha512-5Dlqs/jTsdTUAsd+K5LPLLTgrbbNORUSBQyk8PSy1Mg2zgHDWm83FmvA4s0ooNepCJojFYRITTQ4GU1UUSKYLw==",
"license": "MIT",
"peerDependencies": { "peerDependencies": {
"echarts": "^5.0.1" "echarts": "^5.0.1"
} }
...@@ -4026,6 +4028,18 @@ ...@@ -4026,6 +4028,18 @@
"sprintf-js": "~1.0.2" "sprintf-js": "~1.0.2"
} }
}, },
"node_modules/json5": {
"version": "2.2.3",
"resolved": "https://registry.npmmirror.com/json5/-/json5-2.2.3.tgz",
"integrity": "sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg==",
"license": "MIT",
"bin": {
"json5": "lib/cli.js"
},
"engines": {
"node": ">=6"
}
},
"node_modules/jsonfile": { "node_modules/jsonfile": {
"version": "4.0.0", "version": "4.0.0",
"resolved": "https://registry.npmmirror.com/jsonfile/-/jsonfile-4.0.0.tgz", "resolved": "https://registry.npmmirror.com/jsonfile/-/jsonfile-4.0.0.tgz",
......
...@@ -28,6 +28,7 @@ ...@@ -28,6 +28,7 @@
"echarts-wordcloud": "^2.1.0", "echarts-wordcloud": "^2.1.0",
"element-plus": "^2.4.4", "element-plus": "^2.4.4",
"highlight.js": "^11.11.1", "highlight.js": "^11.11.1",
"json5": "^2.2.3",
"markdown-it": "^14.1.0", "markdown-it": "^14.1.0",
"vue": "^3.4.0", "vue": "^3.4.0",
"vue-router": "^4.2.5" "vue-router": "^4.2.5"
......
<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="16.000000" height="16.000000" fill="none" customFrame="#000000">
<rect id="arrow-up" width="16.000000" height="16.000000" x="0.000000" y="0.000000" />
<path id="Union" d="M7.33343 13.0027L7.33343 5.27885L4.33343 8.27885L3.39062 7.33604L8.0001 2.72656L12.6096 7.33604L11.6668 8.27885L8.66677 5.27885L8.66677 13.0027L7.33343 13.0027Z" fill="rgb(248,52,52)" fill-rule="evenodd" />
</svg>
...@@ -14,12 +14,16 @@ ...@@ -14,12 +14,16 @@
</div> </div>
</div> </div>
</div> </div>
<div class="nav-menu"> <!-- <div class="nav-menu">
<el-dropdown @command="handleHomeCommand" class="home-dropdown"> <el-dropdown @command="handleHomeCommand" class="home-dropdown">
<div class="nav-link dropdown-trigger"> <div class="nav-link dropdown-trigger">
<el-icon><House /></el-icon> <el-icon>
<House />
</el-icon>
<span>首页</span> <span>首页</span>
<el-icon class="dropdown-arrow"><ArrowDown /></el-icon> <el-icon class="dropdown-arrow">
<ArrowDown />
</el-icon>
</div> </div>
<template #dropdown> <template #dropdown>
<el-dropdown-menu> <el-dropdown-menu>
...@@ -27,27 +31,36 @@ ...@@ -27,27 +31,36 @@
<el-dropdown-item command="/decree">政令首页</el-dropdown-item> <el-dropdown-item command="/decree">政令首页</el-dropdown-item>
<el-dropdown-item command="/thinkTank">智库首页</el-dropdown-item> <el-dropdown-item command="/thinkTank">智库首页</el-dropdown-item>
<el-dropdown-item command="/exportControl">出口管制</el-dropdown-item> <el-dropdown-item command="/exportControl">出口管制</el-dropdown-item>
<el-dropdown-item command="/finance">投融资限制</el-dropdown-item>
<el-dropdown-item command="/marketAccessRestrictions">市场准入限制</el-dropdown-item> <el-dropdown-item command="/marketAccessRestrictions">市场准入限制</el-dropdown-item>
</el-dropdown-menu> </el-dropdown-menu>
</template> </template>
</el-dropdown> </el-dropdown>
<div class="nav-link"> <div class="nav-link">
<el-icon><User /></el-icon> <el-icon>
<User />
</el-icon>
<span>国家</span> <span>国家</span>
</div> </div>
<div class="nav-link"> <div class="nav-link">
<el-icon><Location /></el-icon> <el-icon>
<Location />
</el-icon>
<span>领域</span> <span>领域</span>
</div> </div>
<div class="nav-link"> <div class="nav-link">
<el-icon><Document /></el-icon> <el-icon>
<Document />
</el-icon>
<span>要素</span> <span>要素</span>
</div> </div>
<div class="nav-link"> <div class="nav-link">
<el-icon><Bell /></el-icon> <el-icon>
<Bell />
</el-icon>
<span>事件</span> <span>事件</span>
</div> </div>
</div> </div> -->
<div class="user-info"> <div class="user-info">
<div class="email"> <div class="email">
<img src="@/assets/icons/header-icon.png" alt="" /> <img src="@/assets/icons/header-icon.png" alt="" />
...@@ -140,7 +153,6 @@ body { ...@@ -140,7 +153,6 @@ body {
display: flex; display: flex;
justify-content: center; justify-content: center;
align-items: center; align-items: center;
padding: 0 24px;
background: white; background: white;
color: #333; color: #333;
height: 100%; height: 100%;
...@@ -148,7 +160,7 @@ body { ...@@ -148,7 +160,7 @@ body {
box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1); box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
position: relative; position: relative;
box-sizing: border-box; box-sizing: border-box;
height: 96px; height: 64px;
} }
.main-container { .main-container {
...@@ -157,15 +169,17 @@ body { ...@@ -157,15 +169,17 @@ body {
height: 984px; height: 984px;
position: relative; position: relative;
} }
.nav-brand { .nav-brand {
display: flex; display: flex;
align-items: center; align-items: center;
gap: 12px; gap: 12px;
position: absolute; position: absolute;
left: 160px; left: 13px;
.brand-icon { .brand-icon {
width: 48px; width: 48px;
height: 48px; height: 48px;
img { img {
width: 100%; width: 100%;
height: 100%; height: 100%;
...@@ -180,13 +194,14 @@ body { ...@@ -180,13 +194,14 @@ body {
.brand-text { .brand-text {
.text-ch { .text-ch {
height: 42px; height: 37px;
color: rgba(10, 18, 30, 1); color: rgba(10, 18, 30, 1);
font-family: Microsoft YaHei; font-family: Microsoft YaHei;
font-size: 32px; font-size: 28px;
font-weight: 700; font-weight: 700;
line-height: 42px; line-height: 37px;
} }
.text-en { .text-en {
color: rgba(10, 18, 30, 1); color: rgba(10, 18, 30, 1);
font-family: Microsoft YaHei; font-family: Microsoft YaHei;
...@@ -247,23 +262,28 @@ body { ...@@ -247,23 +262,28 @@ body {
border-radius: 6px; border-radius: 6px;
color: #333; color: #333;
position: absolute; position: absolute;
right: 159px; right: 37px;
.email { .email {
width: 20px; width: 20px;
height: 20px; height: 20px;
img { img {
width: 100%; width: 100%;
height: 100%; height: 100%;
} }
} }
.avator { .avator {
width: 32px; width: 32px;
height: 32px; height: 32px;
img { img {
width: 100%; width: 100%;
height: 100%; height: 100%;
} }
} }
.user { .user {
color: rgba(59, 65, 75, 1); color: rgba(59, 65, 75, 1);
font-family: Microsoft YaHei; font-family: Microsoft YaHei;
...@@ -275,19 +295,23 @@ body { ...@@ -275,19 +295,23 @@ body {
.wrapper { .wrapper {
position: relative; position: relative;
.ai-btn { .ai-btn {
position: absolute; position: absolute;
top: 50%; top: 50%;
right: 46px; right: 46px;
cursor: pointer; cursor: pointer;
.icon { .icon {
width: 96px; width: 96px;
height: 96px; height: 96px;
img { img {
width: 100%; width: 100%;
height: 100%; height: 100%;
} }
} }
.text { .text {
height: 24px; height: 24px;
color: rgba(59, 65, 75, 1); color: rgba(59, 65, 75, 1);
...@@ -298,6 +322,7 @@ body { ...@@ -298,6 +322,7 @@ body {
text-align: center; text-align: center;
} }
} }
.ai-dialog { .ai-dialog {
position: absolute; position: absolute;
right: 100px; right: 100px;
...@@ -308,14 +333,16 @@ body { ...@@ -308,14 +333,16 @@ body {
.el-header { .el-header {
padding: 0; padding: 0;
height: 96px; height: 64px;
position: relative; position: relative;
z-index: 1; z-index: 1;
} }
.el-main { .el-main {
padding: 0; padding: 0;
height: calc(100vh - 96px); height: calc(100vh - 64px);
overflow: hidden;
overflow-y: auto;
background-color: rgba(246, 251, 255, 1); background-color: rgba(246, 251, 255, 1);
} }
</style> </style>
/* 声明字体 */
@font-face {
font-family: "YouSheBiaoTiHei";
src: url("./YouSheBiaoTiHei.ttf") format("truetype");
font-weight: normal;
font-style: normal;
font-display: swap; /* 性能优化:先显示备用字体 */
}
/* 全局一次性应用(可选) */
body {
font-family: "YouSheBiaoTiHei", sans-serif;
}
<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="16.000000" height="16.000000" fill="none" customFrame="#000000">
<rect id="form-filled" width="16.000000" height="16.000000" x="0.000000" y="0.000000" />
<path id="Union" d="M14.6667 1.33594L1.33337 1.33594L1.33337 4.66927L14.6667 4.66927L14.6667 1.33594ZM14.6667 6.0026L1.33337 6.0026L1.33337 14.6693L14.6667 14.6693L14.6667 6.0026ZM12 8.33594L12 9.66927L4.00004 9.66927L4.00004 8.33594L12 8.33594ZM9.33337 11.0026L9.33337 12.3359L4.00004 12.3359L4.00004 11.0026L9.33337 11.0026Z" fill="rgb(5,95,194)" fill-opacity="0.800000012" fill-rule="evenodd" />
</svg>
<template> <template>
<div class="policy-tracker-container"> <div class="policy-tracker-container">
<PolicyOverview />
<!-- 顶部搜索栏 --> <!-- 顶部搜索栏 -->
<div class="top-search-bar" v-if="props.showSearch"> <div class="top-search-bar" v-if="props.showSearch">
<div class="search-left"> <div class="search-left">
...@@ -80,6 +81,7 @@ import { Search } from '@element-plus/icons-vue'; ...@@ -80,6 +81,7 @@ import { Search } from '@element-plus/icons-vue';
import PolicyList from './PolicyList.vue'; import PolicyList from './PolicyList.vue';
import CardTitle from './CardTitle.vue'; import CardTitle from './CardTitle.vue';
import { getOverviewPolicy } from '@/api' import { getOverviewPolicy } from '@/api'
import PolicyOverview from '@/views/thinkTank/components/PolicyOverview.vue'
const props = defineProps({ const props = defineProps({
showSearch: { showSearch: {
......
...@@ -38,6 +38,52 @@ export function useMarkdownStream() { ...@@ -38,6 +38,52 @@ export function useMarkdownStream() {
) )
// 关键配置:自定义图片渲染规则
md.renderer.rules.image = function (tokens, idx, options, env, self) {
const token = tokens[idx];
const src = token.attrs[token.attrIndex('src')][1];
const alt = token.content;
const title = token.attrs[token.attrIndex('title')] ? token.attrs[token.attrIndex('title')][1] : '';
// 获取自定义样式参数
const maxWidth = env.maxWidth || '100%';
const height = env.height || 'auto';
const objectFit = env.objectFit || 'cover';
const borderRadius = env.borderRadius || '0px';
const boxShadow = env.boxShadow || 'none';
const display = env.display || 'block';
const margin = env.margin || '0 auto';
// 构建样式字符串
const style = `
max-width: ${maxWidth};
height: ${height};
object-fit: ${objectFit};
border-radius: ${borderRadius};
box-shadow: ${boxShadow};
display: ${display};
margin: ${margin};
`.replace(/\s+/g, ' ').trim();
return `<img src="${src}" alt="${alt}"${title ? ` title="${title}"` : ''} style="${style}" loading="lazy">`;
};
// 链接图片的特殊处理
md.renderer.rules.link_open = function (tokens, idx, options, env, self) {
const token = tokens[idx];
const href = token.attrs[token.attrIndex('href')][1];
// 检查下一个token是否是图片
const nextToken = tokens[idx + 1];
if (nextToken && nextToken.type === 'image') {
// 为包含图片的链接添加特殊样式
const linkStyle = env.linkStyle || 'text-decoration: none; color: inherit;';
return `<a href="${href}" style="${linkStyle}" target="_blank" rel="noopener">`;
}
return self.renderToken(tokens, idx, options);
};
// 自定义代码块渲染规则 // 自定义代码块渲染规则
md.renderer.rules.fence = (tokens, idx, options, env, self) => { md.renderer.rules.fence = (tokens, idx, options, env, self) => {
const token = tokens[idx] const token = tokens[idx]
......
// composables/useMarkdownStream.js
import { ref, computed, nextTick } from 'vue'
import MarkdownIt from 'markdown-it'
import hljs from 'highlight.js'
// 引入 highlight.js 样式
import 'highlight.js/styles/github.css'
import mdKatex from '@traptitech/markdown-it-katex'
export function useStream() {
const rawContent = ref('')
const createMd = () => {
const md = new MarkdownIt(
{
html: true,
breaks: true, // 将换行符转换为 <br>
linkify: true, // 自动链接 URL
typographer: true, // 启用排版扩展
highlight: function (str, lang) {
if (lang && hljs.getLanguage(lang)) {
try {
return '<pre class="hljs" style="fontSize:14px"><code class="language-' + lang + '">' +
hljs.highlight(str, {
language: lang,
ignoreIllegals: true
}).value +
'</code></pre>'
} catch (err) {
console.warn(`代码高亮错误 (${lang}):`, err)
}
}
// 默认处理
return '<pre class="hljs"><code>' + md.utils.escapeHtml(str) + '</code></pre>'
}
}
)
// 自定义代码块渲染规则
md.renderer.rules.fence = (tokens, idx, options, env, self) => {
const token = tokens[idx]
const lang = token.info.trim()
const code = token.content
// 使用 highlight.js 进行高亮
if (lang && hljs.getLanguage(lang)) {
try {
const highlighted = hljs.highlight(code, {
language: lang,
ignoreIllegals: true
})
return `
<div class="code-block-wrapper">
<div class="code-header">
<span class="code-lang">${lang}</span>
</div>
<pre class="hljs"><code class="language-${lang}">${highlighted.value}</code></pre>
</div>
`
} catch (err) {
console.warn(`代码高亮错误 (${lang}):`, err)
}
}
// 默认代码块
return `
<div class="code-block-wrapper">
<div class="code-header">
<span class="code-lang">${lang || 'text'}</span>
<button class="copy-btn" onclick="copyCode(this)">复制</button>
</div>
<pre class="hljs"><code>${md.utils.escapeHtml(code)}</code></pre>
</div>
`
}
// 自定义表格渲染规则
md.renderer.rules.table_open = () =>
'<div class="table-container"><table style="border-collapse: collapse; width: 100%; margin: 1em 0; border: 1px solid #dfe2e5;background: rgb(239 241 243); border-radius: 5px">'
md.renderer.rules.table_close = () => '</table></div>'
md.renderer.rules.thead_open = () => '<thead style="background: #e6e7e8">'
md.renderer.rules.th_open = () =>
'<th style="border: 1px solid #dfe2e5; padding: 12px; text-align: left; font-weight: 600;">'
md.renderer.rules.td_open = () =>
'<td style="border: 1px solid #dfe2e5; padding: 12px; text-align: left; vertical-align: top;">'
md.renderer.rules.th_close = () => '</th>'
md.renderer.rules.td_close = () => '</td>'
md.renderer.rules.tr_open = () => '<tr>'
md.renderer.rules.tr_close = () => '</tr>'
md.renderer.rules.thead_close = () => '</thead>'
md.renderer.rules.tbody_open = () => '<tbody>'
md.renderer.rules.tbody_close = () => '</tbody>'
return md
}
// 渲染 markdown
const renderedProcess = computed(() => {
const md = createMd()
// 预处理内容
return md.render(rawContent.value)
})
// 自动滚动
const scrollToBottom = async (scrollContainer) => {
await nextTick()
if (scrollContainer) {
scrollContainer.scrollTop = scrollContainer.scrollHeight
}
}
// 更新内容并滚动
const updateProcess = async (newContent, scrollContainer) => {
rawContent.value = newContent
await scrollToBottom(scrollContainer)
}
// 清空内容
const clearContent = () => {
rawContent.value = ''
}
return {
rawContent,
renderedProcess,
updateProcess,
clearContent
}
}
\ No newline at end of file
...@@ -9,6 +9,7 @@ import { withFallbackImage } from "./utils"; ...@@ -9,6 +9,7 @@ import { withFallbackImage } from "./utils";
import "./styles/scrollbar.css"; import "./styles/scrollbar.css";
import "./styles/elui.css"; import "./styles/elui.css";
import "./styles/main.css"; import "./styles/main.css";
import '@/assets/fonts/font.css'
const app = createApp(App); const app = createApp(App);
......
差异被折叠。
...@@ -19,9 +19,14 @@ ...@@ -19,9 +19,14 @@
<el-button type="info" plain v-else>全部背景</el-button> <el-button type="info" plain v-else>全部背景</el-button>
</div> </div>
</div> </div>
<div class="header-right"> <div class="header-right">
<img src="./assets/images/header-icon.png" alt="" /> <div class="icon">
</div> <img src="@/assets/icons/box-header-icon2.png" alt="" />
</div>
<div class="icon">
<img src="@/assets/icons/box-header-icon3.png" alt="" />
</div>
</div>
</div> </div>
<div class="box1-main"> <div class="box1-main">
<div class="box1-main-center"> <div class="box1-main-center">
...@@ -59,9 +64,14 @@ ...@@ -59,9 +64,14 @@
<div class="box-header"> <div class="box-header">
<div class="header-left"></div> <div class="header-left"></div>
<div class="title">相关事件</div> <div class="title">相关事件</div>
<div class="header-right"> <div class="header-right">
<img src="./assets/images/header-icon.png" alt="" /> <div class="icon">
</div> <img src="@/assets/icons/box-header-icon2.png" alt="" />
</div>
<div class="icon">
<img src="@/assets/icons/box-header-icon3.png" alt="" />
</div>
</div>
</div> </div>
<div class="box2-main"> <div class="box2-main">
<div <div
...@@ -104,9 +114,14 @@ ...@@ -104,9 +114,14 @@
<el-button type="info" plain v-else>反对议员</el-button> <el-button type="info" plain v-else>反对议员</el-button>
</div> </div>
</div> </div>
<div class="header-right"> <div class="header-right">
<img src="./assets/images/header-icon.png" alt="" /> <div class="icon">
</div> <img src="@/assets/icons/box-header-icon2.png" alt="" />
</div>
<div class="icon">
<img src="@/assets/icons/box-header-icon3.png" alt="" />
</div>
</div>
</div> </div>
<div class="background-wrap-right-main"> <div class="background-wrap-right-main">
<div class="right-box1"> <div class="right-box1">
...@@ -519,23 +534,28 @@ onMounted(() => { ...@@ -519,23 +534,28 @@ onMounted(() => {
.header-btn-box { .header-btn-box {
position: absolute; position: absolute;
top: 14px; top: 14px;
right: 52px; right: 84px;
display: flex; display: flex;
.btn { .btn {
margin-left: 8px; margin-left: 8px;
} }
} }
.header-right { .header-right {
position: absolute; position: absolute;
top: 14px; top: 14px;
right: 12px; right: 12px;
width: 32px; display: flex;
height: 32px; justify-content: flex-end;
img { gap: 4px;
width: 100%; .icon{
height: 100%; width: 28px;
height: 28px;
img{
width: 100%;
height: 100%;
}
} }
} }
} }
.background-wrap-left { .background-wrap-left {
width: 1150px; width: 1150px;
......
...@@ -31,8 +31,13 @@ ...@@ -31,8 +31,13 @@
</div> </div>
<div class="home-box" :class="{ scrollHomeBox: isShow }" ref="containerRef"> <div class="home-box" :class="{ scrollHomeBox: isShow }" ref="containerRef">
<div class="home-header" v-show="!isShow"> <div class="home-header" v-show="!isShow">
<span>国家科技安全 </span>> <span>中美博弈概览 </span>> <!-- <span>国家科技安全 </span>> <span style="cursor: pointer;">中美博弈概览 </span>>
<span>科技法案 </span> <span>科技法案 </span> -->
<div class="header-item">国家科技安全</div>
<div class="header-item">></div>
<div class="header-item back-item" @click="handleBackHome">中美博弈概览</div>
<div class="header-item">></div>
<div class="header-item">科技法案</div>
</div> </div>
<div class="home-main"> <div class="home-main">
<div class="home-main-header" v-show="!isShow"> <div class="home-main-header" v-show="!isShow">
...@@ -566,6 +571,13 @@ import Zyy from "@/assets/icons/zyy.png"; ...@@ -566,6 +571,13 @@ import Zyy from "@/assets/icons/zyy.png";
import Ghd from "@/assets/icons/ghd.png"; import Ghd from "@/assets/icons/ghd.png";
import Mzd from "@/assets/icons/mzd.png"; import Mzd from "@/assets/icons/mzd.png";
// 返回首页
const handleBackHome = () => {
router.push({
path: '/overview'
})
}
const currentPage = ref(1); const currentPage = ref(1);
// 处理页码改变事件 // 处理页码改变事件
const handleCurrentChange = page => { const handleCurrentChange = page => {
...@@ -1073,79 +1085,77 @@ const box9ChartData = ref([ ...@@ -1073,79 +1085,77 @@ const box9ChartData = ref([
const box7Data = ref([ const box7Data = ref([
[ [
{ {
name: '众议院', name: "众议院",
value: 298 value: 298
}, },
{ {
name: '参议院', name: "参议院",
value: 149 value: 149
} }
], ],
[ [
{ {
name: '拨款委员会', name: "拨款委员会",
value: 50, value: 50,
type: '众议院' type: "众议院"
}, },
{ {
name: '筹款委员会', name: "筹款委员会",
value: 50, value: 50,
type: '众议院' type: "众议院"
}, },
{ {
name: '外交事务委员会', name: "外交事务委员会",
value: 46, value: 46,
type: '众议院' type: "众议院"
}, },
{ {
name: '国土安全委员会', name: "国土安全委员会",
value: 40, value: 40,
type: '众议院' type: "众议院"
}, },
{ {
name: '司法委员会', name: "司法委员会",
value: 40, value: 40,
type: '众议院' type: "众议院"
}, },
{ {
name: '军事委员会', name: "军事委员会",
value: 40, value: 40,
type: '众议院' type: "众议院"
}, },
{ {
name: '能源和商业委员会', name: "能源和商业委员会",
value: 32, value: 32,
type: '众议院' type: "众议院"
}, },
{ {
name: '拨款委员会1', name: "拨款委员会1",
value: 32, value: 32,
type: '参议院' type: "参议院"
}, },
{ {
name: '财政委员会', name: "财政委员会",
value: 31, value: 31,
type: '参议院' type: "参议院"
}, },
{ {
name: '能源', name: "能源",
value: 30, value: 30,
type: '参议院' type: "参议院"
}, },
{ {
name: '能源1', name: "能源1",
value: 30, value: 30,
type: '参议院' type: "参议院"
}, },
{ {
name: '其他', name: "其他",
value: 24, value: 24,
type: '参议院' type: "参议院"
} }
] ]
]) ]);
const box8Data = ref([ const box8Data = ref([
{ {
...@@ -1203,8 +1213,8 @@ onMounted(async () => { ...@@ -1203,8 +1213,8 @@ onMounted(async () => {
const wordCloudChart = getWordCloudChart(wordCloudData.value); const wordCloudChart = getWordCloudChart(wordCloudData.value);
setChart(wordCloudChart, "wordCloudChart"); setChart(wordCloudChart, "wordCloudChart");
const box7Chart = getDoublePieChart(box7Data.value[0], box7Data.value[1]) const box7Chart = getDoublePieChart(box7Data.value[0], box7Data.value[1]);
setChart(box7Chart, 'box7Chart') setChart(box7Chart, "box7Chart");
const box9Chart = getPieChart(box9ChartData.value, box9ChartColorList.value); const box9Chart = getPieChart(box9ChartData.value, box9ChartColorList.value);
setChart(box9Chart, "box9Chart"); setChart(box9Chart, "box9Chart");
...@@ -1328,6 +1338,16 @@ onMounted(async () => { ...@@ -1328,6 +1338,16 @@ onMounted(async () => {
background: url("./assets/images/header-bg.png"); background: url("./assets/images/header-bg.png");
box-sizing: border-box; box-sizing: border-box;
padding-left: 160px; padding-left: 160px;
display: flex;
.header-item {
margin: 0 3px;
}
.back-item {
cursor: pointer;
&:hover {
color: #ccc;
}
}
} }
.home-main { .home-main {
width: 1600px; width: 1600px;
...@@ -1565,9 +1585,10 @@ onMounted(async () => { ...@@ -1565,9 +1585,10 @@ onMounted(async () => {
.box1-main-left-info { .box1-main-left-info {
margin-top: 17px; margin-top: 17px;
display: flex; display: flex;
gap: 8px;
.info-box { .info-box {
height: 30px; max-width: 80px;
width: 80px; height: 24px;
text-align: center; text-align: center;
overflow: hidden; overflow: hidden;
padding: 0 8px; padding: 0 8px;
...@@ -1579,8 +1600,7 @@ onMounted(async () => { ...@@ -1579,8 +1600,7 @@ onMounted(async () => {
font-family: Microsoft YaHei; font-family: Microsoft YaHei;
font-size: 14px; font-size: 14px;
font-weight: 400; font-weight: 400;
line-height: 30px; line-height: 24px;
margin-right: 8px;
} }
.info1 { .info1 {
border: 1px solid rgba(135, 232, 222, 1); border: 1px solid rgba(135, 232, 222, 1);
...@@ -2335,7 +2355,7 @@ onMounted(async () => { ...@@ -2335,7 +2355,7 @@ onMounted(async () => {
align-items: center; align-items: center;
justify-content: flex-end; justify-content: flex-end;
} }
.box7-main{ .box7-main {
height: 340px; height: 340px;
} }
} }
...@@ -2592,15 +2612,18 @@ onMounted(async () => { ...@@ -2592,15 +2612,18 @@ onMounted(async () => {
.btn-wrapper { .btn-wrapper {
width: 1300px; width: 1300px;
overflow-x: auto; overflow-x: auto;
// background: skyblue;
.btn-box { .btn-box {
display: flex; display: flex;
gap: 4px;
// justify-content: space-between; // justify-content: space-between;
max-width: 2000px; max-width: 2000px;
// background: orange;
.btn { .btn {
max-width: 100px; max-width: 120px;
min-width: 80px; min-width: 80px;
height: 42px; height: 42px;
margin: 0 5px;
overflow: hidden; overflow: hidden;
color: rgba(95, 101, 108, 1); color: rgba(95, 101, 108, 1);
font-family: Microsoft YaHei; font-family: Microsoft YaHei;
...@@ -2610,7 +2633,7 @@ onMounted(async () => { ...@@ -2610,7 +2633,7 @@ onMounted(async () => {
text-align: center; text-align: center;
border-radius: 21px; border-radius: 21px;
background: rgba(20, 89, 187, 0); background: rgba(20, 89, 187, 0);
padding: 0 16px; padding: 0 20px;
cursor: pointer; cursor: pointer;
&:hover { &:hover {
background: rgba(20, 89, 187, 0.1); background: rgba(20, 89, 187, 0.1);
......
...@@ -118,17 +118,6 @@ ...@@ -118,17 +118,6 @@
</div> </div>
</div> </div>
</div> </div>
<div class="tool-box">
<div class="tool1">
<img src="./assets/icons/tool-icon1.png" alt="" />
</div>
<div class="tool2">
<img src="./assets/icons/tool-icon2.png" alt="" />
</div>
<div class="tool3">
<img src="./assets/icons/tool-icon3.png" alt="" />
</div>
</div>
</div> </div>
</template> </template>
...@@ -136,23 +125,6 @@ ...@@ -136,23 +125,6 @@
import { ref, onMounted } from "vue"; import { ref, onMounted } from "vue";
import router from "@/router"; import router from "@/router";
import GJKJAQImg from "./assets/images/icon1.png";
import GJKJAQActiveImg from "./assets/images/icon1.png";
import KJLYImg from "./assets/images/icon2.png";
import KJLYActiveImg from "./assets/images/icon2.png";
import KJYSImg from "./assets/images/icon3.png";
import KJYSActiveImg from "./assets/images/icon3.png";
import ZDKJAQImg from "./assets/images/icon4.png";
import ZDKJAQActiveImg from "./assets/images/icon4.png";
import ZBTXImg from "./assets/images/icon5.png";
import ZBTXActiveImg from "./assets/images/icon5.png";
import ZJKImg from "./assets/images/icon6.png";
import ZJKActiveImg from "./assets/images/icon6.png";
import XTGLImg from "./assets/images/icon7.png";
import XTGLActiveImg from "./assets/images/icon7.png";
import search from "./assets/images/search.png";
import mail from "./assets/images/mail.png";
import icon1 from "./assets/icons/icon1.png"; import icon1 from "./assets/icons/icon1.png";
import icon1Active from "./assets/icons/icon1_active.png"; import icon1Active from "./assets/icons/icon1_active.png";
import icon2 from "./assets/icons/icon2.png"; import icon2 from "./assets/icons/icon2.png";
...@@ -162,12 +134,6 @@ import icon3Active from "./assets/icons/icon3_active.png"; ...@@ -162,12 +134,6 @@ import icon3Active from "./assets/icons/icon3_active.png";
import icon4 from "./assets/icons/icon4.png"; import icon4 from "./assets/icons/icon4.png";
import icon4Active from "./assets/icons/icon4_active.png"; import icon4Active from "./assets/icons/icon4_active.png";
import headerIcon1 from "./assets/icons/header-icon1.png";
import headerIcon2 from "./assets/icons/header-icon2.png";
import headerIcon3 from "./assets/icons/header-icon3.png";
import headerIcon4 from "./assets/icons/header-icon4.png";
import headerIcon5 from "./assets/icons/header-icon5.png";
const activeName = ref("分析报告"); const activeName = ref("分析报告");
const handleSwitchActiveName = (name) => { const handleSwitchActiveName = (name) => {
...@@ -222,13 +188,6 @@ const handleClickMainHeaderBtn = (item) => { ...@@ -222,13 +188,6 @@ const handleClickMainHeaderBtn = (item) => {
router.push(item.path); router.push(item.path);
}; };
const activeNavIndex = ref(0);
const handleClickNav = (index, item) => {
activeNavIndex.value = index;
router.push(item.path);
};
onMounted(() => { onMounted(() => {
if(window.sessionStorage.getItem('activeTitle')) { if(window.sessionStorage.getItem('activeTitle')) {
activeTitle.value = window.sessionStorage.getItem('activeTitle') activeTitle.value = window.sessionStorage.getItem('activeTitle')
...@@ -239,7 +198,6 @@ onMounted(() => { ...@@ -239,7 +198,6 @@ onMounted(() => {
<style lang="scss" scoped> <style lang="scss" scoped>
.layout-container { .layout-container {
width: 1920px; width: 1920px;
// height: 1080px;
height: 1016px; height: 1016px;
background: rgba(249, 250, 252, 1); background: rgba(249, 250, 252, 1);
position: relative; position: relative;
...@@ -623,49 +581,5 @@ onMounted(() => { ...@@ -623,49 +581,5 @@ onMounted(() => {
} }
} }
} }
.tool-box {
position: fixed;
z-index: 10000;
bottom: 80px;
left: 0;
width: 48px;
height: 144px;
border-radius: 0px 10px 10px 0px;
box-shadow: 0px 0px 15px 0px rgba(22, 119, 255, 0.1);
background: rgba(255, 255, 255, 1);
.tool1 {
width: 17px;
height: 18px;
margin-top: 17px;
margin-left: 16px;
cursor: pointer;
img {
width: 100%;
height: 100%;
}
}
.tool2 {
width: 22px;
height: 20px;
margin-top: 26px;
margin-left: 14px;
cursor: pointer;
img {
width: 100%;
height: 100%;
}
}
.tool3 {
width: 20px;
height: 20px;
margin-top: 25px;
margin-left: 15px;
cursor: pointer;
img {
width: 100%;
height: 100%;
}
}
}
} }
</style> </style>
\ No newline at end of file
const getBoxPlotChcart = (data) => { const getBoxPlotChcart = (data,unit) => {
let option = { let option = {
// title: [ // title: [
// { // {
...@@ -34,7 +34,12 @@ const getBoxPlotChcart = (data) => { ...@@ -34,7 +34,12 @@ const getBoxPlotChcart = (data) => {
}, },
yAxis: { yAxis: {
type: 'value', type: 'value',
name: '单位:天', name: `单位:${unit}`,
nameTextStyle: {
padding: [0, 0, 0, 1520], // [上, 右, 下, 左]
verticalAlign: 'middle',
align: 'center'
},
splitArea: { splitArea: {
show: true show: true
} }
...@@ -46,7 +51,7 @@ const getBoxPlotChcart = (data) => { ...@@ -46,7 +51,7 @@ const getBoxPlotChcart = (data) => {
datasetIndex: 1, datasetIndex: 1,
data: data.dataY, data: data.dataY,
}, },
{ {
name: 'outlier', name: 'outlier',
type: 'scatter', type: 'scatter',
datasetIndex: 2 datasetIndex: 2
......
...@@ -3,9 +3,14 @@ ...@@ -3,9 +3,14 @@
<div class="box-header"> <div class="box-header">
<div class="header-left"></div> <div class="header-left"></div>
<div class="title">流程概要</div> <div class="title">流程概要</div>
<div class="header-right"> <div class="header-right">
<img src="./assets/images/header-icon.png" alt="" /> <div class="icon">
</div> <img src="@/assets/icons/box-header-icon2.png" alt="" />
</div>
<div class="icon">
<img src="@/assets/icons/box-header-icon3.png" alt="" />
</div>
</div>
</div> </div>
<div class="main"> <div class="main">
<div class="left"> <div class="left">
...@@ -754,17 +759,22 @@ const handleClickDetail = (isShow) => { ...@@ -754,17 +759,22 @@ const handleClickDetail = (isShow) => {
font-weight: 600; font-weight: 600;
line-height: 16px; line-height: 16px;
} }
.header-right { .header-right {
position: absolute; position: absolute;
top: 14px; top: 14px;
right: 12px; right: 12px;
width: 32px; display: flex;
height: 32px; justify-content: flex-end;
img { gap: 4px;
width: 100%; .icon {
height: 100%; width: 28px;
} height: 28px;
} img {
width: 100%;
height: 100%;
}
}
}
} }
.main { .main {
margin-left: 59px; margin-left: 59px;
......
差异被折叠。
差异被折叠。
差异被折叠。
差异被折叠。
差异被折叠。
差异被折叠。
差异被折叠。
差异被折叠。
差异被折叠。
差异被折叠。
差异被折叠。
差异被折叠。
差异被折叠。
差异被折叠。
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论