瀏覽代碼

Make sure each Combat component has its own log

vintage
Fen Dweller 5 年之前
父節點
當前提交
5469fa53ec
共有 1 個檔案被更改,包括 20 行新增20 行删除
  1. +20
    -20
      src/components/Combat.vue

+ 20
- 20
src/components/Combat.vue 查看文件

@@ -11,7 +11,7 @@
<div class="statblock-separator" id="statblock-separator-left"></div>
<div class="statblock-separator" id="statblock-separator-center"></div>
<div class="statblock-separator" id="statblock-separator-right"></div>
<div id="log">
<div class="log">
</div>
<div class="left-fader">

@@ -91,7 +91,7 @@ export default class Combat extends Vue {

@Emit("executedLeft")
executedLeft (entry: LogEntry) {
const log = document.querySelector("#log")
const log = this.$el.querySelector(".log")
if (log !== null) {
const before = log.querySelector("div.log-entry")
const holder = document.createElement("div")
@@ -116,7 +116,7 @@ export default class Combat extends Vue {

@Emit("executedRight")
executedRight (entry: LogEntry) {
const log = document.querySelector("#log")
const log = this.$el.querySelector(".log")

if (log !== null) {
const before = log.querySelector("div.log-entry")
@@ -240,7 +240,7 @@ export default class Combat extends Vue {
overflow: hidden;
}

#log {
.log {
grid-area: main-row-start / main-col-start / main-row-end / main-col-end;
overflow-y: scroll;
font-size: 12pt;
@@ -380,7 +380,7 @@ a {
white-space: nowrap;
}

#log > div.log-entry {
.log > div.log-entry {
color: #888;
padding-top: 4pt;
padding-bottom: 4pt;
@@ -403,63 +403,63 @@ div.right-move {
margin-right: 2%;
}

#log img {
.log img {
width: 75%;
}

#log > div.left-move:nth-child(7) {
.log > div.left-move:nth-child(7) {
color: #898;
}

#log > div.left-move:nth-child(6) {
.log > div.left-move:nth-child(6) {
color: #8a8;
}

#log > div.left-move:nth-child(5) {
.log > div.left-move:nth-child(5) {
color: #8b8;
}

#log > div.left-move:nth-child(4) {
.log > div.left-move:nth-child(4) {
color: #8c8;
}

#log > div.left-move:nth-child(3) {
.log > div.left-move:nth-child(3) {
color: #8d8;
}

#log > div.left-move:nth-child(2) {
.log > div.left-move:nth-child(2) {
color: #8e8;
}

#log > div.left-move:nth-child(1) {
.log > div.left-move:nth-child(1) {
color: #8f8;
}

#log > div.right-move:nth-child(7) {
.log > div.right-move:nth-child(7) {
color: #988;
}

#log > div.right-move:nth-child(6) {
.log > div.right-move:nth-child(6) {
color: #a88;
}

#log > div.right-move:nth-child(5) {
.log > div.right-move:nth-child(5) {
color: #b88;
}

#log > div.right-move:nth-child(4) {
.log > div.right-move:nth-child(4) {
color: #c88;
}

#log > div.right-move:nth-child(3) {
.log > div.right-move:nth-child(3) {
color: #d88;
}

#log > div.right-move:nth-child(2) {
.log > div.right-move:nth-child(2) {
color: #e88;
}

#log > div.right-move:nth-child(1) {
.log > div.right-move:nth-child(1) {
color: #f88;
}



Loading…
取消
儲存