diff --git a/docs/修改记录.md b/docs/修改记录.md index b9733e2..9ca4500 100644 --- a/docs/修改记录.md +++ b/docs/修改记录.md @@ -153,3 +153,59 @@ **刻意未做**:麻将胡了的 **11 张 `game_mahjong_*` 游戏表尚未落库**(DDL + 种子在 `mahjong-py/schema.sql`)。 这 7 个新菜单页面依赖它们,未建表前打开会报「表不存在」。属「游戏本体」前置依赖、且 generator 还没写完 (见 `mahjong-py/README.md`),**待用户确认后再执行**。 + +- **后台管理端(`ruoyi-ui`)整站换肤:Cottagecore 田园核风 + 逐页 UI 细节收敛** + + **起因**:管理后台长期沿用它默认的企业蓝(Element 默认色板 + vue-element-admin / AdminLTE 遗留色),与河南项目的 + 田园调性不符;用户要求按 Cottagecore 规范整站重做,并**逐页检查小问题、把 UI 细节调到位**。 + + **做法:不引 Tailwind,走「Element 变量 + 皮肤覆盖层」** + (`ruoyi-ui` 是 Vue2 + Element UI 2.15 + vue-cli4/webpack4/postcss7,Tailwind 的 preflight 会打乱 Element 基础样式)。 + 新建 **`src/assets/styles/cottagecore.scss` 作为全站唯一色源**,其余文件一律引用变量、不写死十六进制; + 再通过重编译 `element-ui` 的 theme-chalk 源码(`element-variables.scss`)换掉 Element 自己的底色。 + + | 文件 | 角色 | + |---|---| + | `assets/styles/cottagecore.scss` | **唯一色源**:品牌色 + 组件槽位色 + 图标色相 + 对比度实测注释 | + | `assets/styles/element-variables.scss` | 覆盖 `$--color-*` / 圆角 / 阴影 / `$--color-white` → 暖白 `#fffdfa`,再 `@import` theme-chalk 源码整包编译 | + | `assets/styles/skin.scss` | 皮肤覆盖层(按钮 / 表单 / 表格 / 分页 / 弹层 / Element 写死的冷色) | + | `assets/styles/index.scss` | 总入口,**最后一行 `@import './skin.scss'`**(整体回滚 = 注释这一行) | + | `assets/styles/sidebar.scss` / `variables.scss` | 侧栏(4 色图标轮换)/ 菜单深浅两套色 + `:export` 给 js | + + **六轮递进,要点**: + + 1. **建色源 + 换 Element 底色**:primary 定陶土 `#9a5c35`(**不用草绿**,否则「新增 / 修改」同色系分不清; + 想切回只改色源一处),success 草绿 `#457450`,warning 深雏菊金 `#8f6418`,danger 莓红 `#a4485a`,info 暖褐 `#6b6152`。 + 正文 `#5f4f3d`(**`#8b7355` 只有 4.17:1,禁止做正文**);草绿 `#5a8f5a` 白字仅 3.81:1 ⇒ **只做装饰与大色块**, + 绿色文字一律 `#3f6b45`。 + 2. **摘掉隐藏的 ThemePicker**:`App.vue` 曾无条件挂 ``(只用 CSS `display:none` 藏,组件照样 mount), + 它在 `created()` 里会去 `unpkg.com` 拉整包 Element 默认主题并注入 ` diff --git a/ruoyi-ui/src/components/Pagination/index.vue b/ruoyi-ui/src/components/Pagination/index.vue index 56f5a6b..418fbe5 100644 --- a/ruoyi-ui/src/components/Pagination/index.vue +++ b/ruoyi-ui/src/components/Pagination/index.vue @@ -104,10 +104,12 @@ export default { diff --git a/ruoyi-ui/src/views/game/mahjong/prize/index.vue b/ruoyi-ui/src/views/game/mahjong/prize/index.vue index 5c9478a..930c898 100644 --- a/ruoyi-ui/src/views/game/mahjong/prize/index.vue +++ b/ruoyi-ui/src/views/game/mahjong/prize/index.vue @@ -80,7 +80,7 @@ -
未命中区间时随机选择一个兜底饰品返奖
+
未命中区间时随机选择一个兜底饰品返奖
@@ -88,7 +88,7 @@ ~
-
玩家结算赢额落在该区间即获得此饰品(最高到 500x 封顶对应的赢额)
+
玩家结算赢额落在该区间即获得此饰品(最高到 500x 封顶对应的赢额)
diff --git a/ruoyi-ui/src/views/game/mahjong/rewardPool/index.vue b/ruoyi-ui/src/views/game/mahjong/rewardPool/index.vue index d17d49a..a32516a 100644 --- a/ruoyi-ui/src/views/game/mahjong/rewardPool/index.vue +++ b/ruoyi-ui/src/views/game/mahjong/rewardPool/index.vue @@ -69,13 +69,13 @@
-
{{ audienceLabel(audience) }}·总池余额

{{ fmt(pool.balance) }}

+
{{ audienceLabel(audience) }}·总池余额

{{ fmt(pool.balance) }}

-
{{ audienceLabel(audience) }}·实时RTP

{{ rtpPct(pool.rtp).toFixed(1) }}%

+
{{ audienceLabel(audience) }}·实时RTP

{{ rtpPct(pool.rtp).toFixed(1) }}%

@@ -130,7 +130,7 @@ @@ -146,18 +146,18 @@ @@ -198,13 +198,13 @@
- {{ fmt(form.balance) }} + {{ fmt(form.balance) }} - {{ fmt(afterBalance) }} + {{ fmt(afterBalance) }} @@ -234,7 +234,7 @@ @@ -247,13 +247,13 @@ @@ -329,7 +329,7 @@ export default { }, signColor(v) { const n = Number(v) - return n < 0 ? '#f56c6c' : (n > 0 ? '#67c23a' : '#303133') + return n < 0 ? '#a4485a' : (n > 0 ? '#457450' : '#4f4130') }, applyConfig(data) { if (!data) return @@ -423,30 +423,33 @@ export default { diff --git a/ruoyi-ui/src/views/game/wheel/config/index.vue b/ruoyi-ui/src/views/game/wheel/config/index.vue index c1ccbca..2fac90d 100644 --- a/ruoyi-ui/src/views/game/wheel/config/index.vue +++ b/ruoyi-ui/src/views/game/wheel/config/index.vue @@ -205,7 +205,7 @@
单局奖池投放比例 (bufferRatio = {{ config.bufferRatio }}):一局最多从奖池拿出 {{ bufferRatioPct }} 的余额 来发奖
-
+
• 例:奖池余额 10000 元 → 本项上限 10000 × {{ config.bufferRatio }} = {{ poolCapDemo }} 元
• 奖池 = 累计真实下注 − 累计真实返奖(机器人、白号不计)
• 口径提醒:这里填的是"最多拿出多少",不是"保留多少"——{{ config.bufferRatio }} = 最多拿出 {{ bufferRatioPct }},剩下 {{ bufferKeepPct }} 留在池里 @@ -214,7 +214,7 @@
目标RTP (rtp = {{ config.rtp }},累计口径):按"总共该发多少 − 已经发了多少"算出还能发多少,这就是本局的返奖预算(是发奖上限,不是平台欠玩家钱)
-
+
• 本局可发额度 = 累计真实投注 × {{ rtpPct }} − 累计真实返奖;
• 例:累计投注 10 万、累计返奖 7 万 → 该发 {{ rtpDemo.should }} 万、已发 7 万 → 本局额度 {{ rtpDemo.room }} 万
• 它只是"这局最多能发多少":实际发多少仍由转盘概率决定,没发完的额度继续攒到以后(所以池子厚了能一局爆大奖)。本局投注在封盘时已计入累计,历史刚好发到 {{ rtpPct }} 时,额度正好 = 本局投注 × {{ rtpPct }}
@@ -222,8 +222,8 @@ • 实际返奖率请以首页「实时RTP」为准,不要拿本配置值当预期
-
- 协同机制:发奖上限 = min(奖池余额×{{ config.bufferRatio }}, 本局可发额度),两条都要满足
+
+ 协同机制:发奖上限 = min(奖池余额×{{ config.bufferRatio }}, 本局可发额度),两条都要满足
• 谁小听谁的:池子不够厚 → 按奖池的 {{ bufferRatioPct }} 卡;池子够厚 → 按返奖额度卡
• 额度够时,单局返奖可以远超本局投注("池子厚就能爆大奖")
@@ -255,7 +255,7 @@ export default { poolStatsList: [], multiplierTable: [ { color: 'gold', A: 1, B: 1, C: 1, D: 1 }, - { color: 'red', A: 1, B: 1, C: 1, D: 1 }, + { color: '#a4485a', A: 1, B: 1, C: 1, D: 1 }, { color: 'purple', A: 1, B: 1, C: 1, D: 1 } ], // 奖池调节相关 @@ -353,7 +353,7 @@ export default { }, syncMultiplierTable() { const multipliers = this.config.multipliers || []; - const colors = ['gold', 'red', 'purple']; + const colors = ['gold', '#a4485a', 'purple']; const symbols = ['A', 'B', 'C', 'D']; this.multiplierTable = colors.map(color => { const row = { color }; diff --git a/ruoyi-ui/src/views/game/wheel/prize/index.vue b/ruoyi-ui/src/views/game/wheel/prize/index.vue index aa94fcc..b5a5187 100644 --- a/ruoyi-ui/src/views/game/wheel/prize/index.vue +++ b/ruoyi-ui/src/views/game/wheel/prize/index.vue @@ -9,7 +9,7 @@ - + - +