Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
R
rrpgLink_FrontEnd
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kesaubeeire
rrpgLink_FrontEnd
Commits
031bb10f
Commit
031bb10f
authored
Oct 25, 2023
by
KesaubeEire
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: config 加入新参数.
parent
62a7b915
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
49 additions
and
9 deletions
+49
-9
src/components/MenuConfig.svelte
src/components/MenuConfig.svelte
+16
-2
src/components/card.svelte
src/components/card.svelte
+28
-6
src/stores/index.js
src/stores/index.js
+5
-1
No files found.
src/components/MenuConfig.svelte
View file @
031bb10f
...
...
@@ -53,8 +53,22 @@
<div class="flex flex-col">
<div class="form-control w-60">
<label class="label cursor-pointer w-full inline-flex justify-between">
<span class="label-text">显示语言分类</span>
<input type="checkbox" bind:checked={$_config.card_showCateGory} class="toggle" />
<span class="label-text">显示游戏ID</span>
<input type="checkbox" bind:checked={$_config.card_showId} class="toggle" />
</label>
</div>
<div class="form-control w-60">
<label class="label cursor-pointer w-full inline-flex justify-between">
<span class="label-text">显示语言: 标题</span>
<input type="checkbox" bind:checked={$_config.card_showCateGoryTitle} class="toggle" />
</label>
</div>
<div class="form-control w-60">
<label class="label cursor-pointer w-full inline-flex justify-between">
<span class="label-text">显示语言: 标签</span>
<input type="checkbox" bind:checked={$_config.card_showCateGoryTag} class="toggle" />
</label>
</div>
...
...
src/components/card.svelte
View file @
031bb10f
...
...
@@ -114,11 +114,20 @@
onclick="globalModal.showModal()"
on:keypress={() => {}}
/>
{#if $_config.card_showId}
<div
class="
absolute w-10 right-0 top-0 p-1 text-center
bg-neutral text-neutral-content rounded-bl-box border border-neutral"
>
{id}
</div>
{/if}
</figure>
<div class="card-body justify-between">
<h2 class="card-title block text-lg">
<!-- NOTE: 游戏类别 -->
{#if $_config.card_showCateGory}
<!-- NOTE: 游戏类别
(title)
-->
{#if $_config.card_showCateGory
Title
}
<div
class="badge badge-secondary m-auto cursor-pointer hover:badge-neutral"
style="height: inherit;line-height: inherit;"
...
...
@@ -143,8 +152,8 @@
{/if}
<!-- NOTE: tags -->
{#if $_config.card_showTag}
<div class="card-actions justify-end">
<div class="card-actions justify-end">
{#if $_config.card_showTag}
{#if !raw_tags || tags.length == 0}
<!-- <div class="badge badge-outline">Tag 示例</div> -->
{:else}
...
...
@@ -160,8 +169,21 @@
</div>
{/each}
{/if}
</div>
{/if}
{/if}
<!-- NOTE: 游戏类别(tag) -->
{#if $_config.card_showCateGoryTag}
<div class="tooltip">
<div
class="badge badge-secondary cursor-pointer hover:badge-outline hover:bg-neutral hover:text-neutral-content"
on:click={p_searchCategory(category)}
on:keypress={() => {}}
>
{language ?? '示例'}
</div>
</div>
{/if}
</div>
</div>
</div>
...
...
src/stores/index.js
View file @
031bb10f
...
...
@@ -41,12 +41,16 @@ export const _env = persistStore('_env', "");
/** 永久持久化: 配置 */
export
const
_config
=
persistStore
(
'
_config
'
,
{
// 卡片配置 显示游戏ID
card_showId
:
true
,
// 卡片配置 显示副标题
card_showSubTitle
:
true
,
// 卡片配置 显示标签
card_showTag
:
true
,
// 卡片配置 显示语言分类
card_showCateGory
:
true
,
card_showCateGoryTitle
:
true
,
// 卡片配置 显示语言分类
card_showCateGoryTag
:
false
,
// 分页配置 单页显示(单次瀑布流加载)数量
page_singleNum
:
20
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment