Skip to content

Commit

Permalink
調整とこの仕様に関する説明を記述
Browse files Browse the repository at this point in the history
  • Loading branch information
Appbird committed Sep 3, 2021
1 parent 73646a4 commit cfc2785
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
7 changes: 6 additions & 1 deletion src/ts/client/view/parts/RuleIndexPart.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@ const contents={
Japanese: "全セグメント",
English: "All Segments"
},
ruleIndexClickable:{
Japanese: "下の目次をクリックすると、そのルールの詳細へ飛ぶことが出来ます。",
English: "If you click on the index below, you will jump to the detailed description of the rule."
},
specify_priority_in_ruleClasses:{
Japanese: "もっとも上にあるアイテムが基本的にルールとして優先されます。",
English: "If the scope of rule classes is duplicated and contradicts each other, the item at the top has priority."
Expand Down Expand Up @@ -58,8 +62,9 @@ export class RuleIndexPart {
return
}
const ruleIndexSegment = this.container.appendChild(elementWithoutEscaping`
<div class="c-ruleIndex u-width90per">
<div class="c-ruleIndex u-width90per u-clickable">
<div class="__indexTitle">${choiceString(contents.indexTitle,this.language).replace(/\$\{number\}/g,this.rules.length.toString())}</div>
<div class="__indexTitle">${choiceString(contents.ruleIndexClickable,this.language)}</div>
<div class="__indexTitle u-bolderChara">${choiceString(contents.specify_priority_in_ruleClasses,this.language)}</div>
<div class="__list">
<div class="__item --top u-smallerChara">
Expand Down
2 changes: 1 addition & 1 deletion src/ts/client/view/state/gameModeRule.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ export class S_GameModeRule extends PageStateBaseClass<{gameSystemID:string,game
view.setHeader(ruleObj.rule)
view.setRule(ruleObj)
view.setNote(ruleObj.rule)
const destinationYPosition = ruleDetailedSegment.getBoundingClientRect().y + window.scrollY - (window.innerHeight/10)
const destinationYPosition = ruleDetailedSegment.getBoundingClientRect().y + window.scrollY
ruleIndexPart.appendNewRule(ruleObj,() => this.app.scrollToThePagePosition(destinationYPosition))
}
ruleIndexPart.refrectView()
Expand Down

0 comments on commit cfc2785

Please sign in to comment.