Skip to content

Commit

Permalink
Merge branch 'release/2.20.11' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
Lakeyzer committed Feb 5, 2024
2 parents 50abf16 + 694073d commit ffda1a7
Show file tree
Hide file tree
Showing 5 changed files with 90 additions and 95 deletions.
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"version": "2.20.10",
"version": "2.20.11",
"name": "harmless_key",
"description": "A Dungeons and Dragons Combat Tracker",
"productName": "Harmless Key",
Expand Down
10 changes: 9 additions & 1 deletion src/components/combat/actions/Actions.vue
Original file line number Diff line number Diff line change
Expand Up @@ -285,19 +285,26 @@ export default {
}
}
}
&::v-deep {
.q-tab {
width: 100%;
}
}
}
.modes {
&::v-deep {
.q-tabs {
&__content {
padding: 10px;
margin: -10px;
gap: 0.5rem;
.q-tab {
border: solid 1px transparent;
border-radius: $border-radius;
width: 100%;
&:focus {
outline: $outline;
Expand All @@ -308,6 +315,7 @@ export default {
}
}
.q-tab-panel {
padding: 15px 0 0 0 !important;
}
Expand Down
143 changes: 71 additions & 72 deletions src/components/combat/actions/custom/CustomRoll.vue
Original file line number Diff line number Diff line change
Expand Up @@ -16,90 +16,89 @@
]"
@input="setType"
/>
<q-form>
<q-input
v-if="roll_type === 'attack'"
:dark="$store.getters.theme === 'dark'"
dense
filled
square
type="number"
v-model="attack_bonus"
label="Attack bonus"
/>
<div v-if="roll_type === 'save'" class="d-flex justify-content-between">
<q-select
:dark="$store.getters.theme === 'dark'"
dense
filled
square
map-options
emit-value
label="Save ability"
:options="abilities"
v-model="save_ability"
class="mr-1"
/>
<q-input
v-if="roll_type === 'attack'"
:dark="$store.getters.theme === 'dark'"
dense
filled
square
type="number"
v-model="attack_bonus"
label="Attack bonus"
v-model="save_dc"
label="Save DC"
/>
<div v-if="roll_type === 'save'" class="d-flex justify-content-between">
<q-select
:dark="$store.getters.theme === 'dark'"
dense
filled
square
map-options
emit-value
label="Save ability"
:options="abilities"
v-model="save_ability"
class="mr-1"
/>
<q-input
:dark="$store.getters.theme === 'dark'"
dense
filled
square
type="number"
v-model="save_dc"
label="Save DC"
/>
</div>
</div>

<!-- CUSTOM ROLL -->
<h3>
Rolls
<a @click="addRoll">
<i aria-hidden="true" class="fas fa-plus green" />
</a>
</h3>
<!-- CUSTOM ROLL -->
<h3>
Rolls
<a @click="addRoll">
<i aria-hidden="true" class="fas fa-plus green" />
</a>
</h3>

<div v-for="(roll, index) in custom_rolls" class="custom-roll" :key="`roll-${index}`">
<q-input
:ref="index"
:dark="$store.getters.theme === 'dark'"
filled
square
dense
label="Roll"
autocomplete="off"
v-model="custom_rolls[index].roll"
lazy-rules
:rules="[
(val) => !!val || 'Roll is required',
(val) => val.match(/^[0-9]+d[0-9]+(\+[0-9])?$/) || 'Allowed format: 2d6 or 2d6+1',
]"
/>
<div v-for="(roll, index) in custom_rolls" class="custom-roll" :key="`roll-${index}`">
<q-input
:ref="index"
:dark="$store.getters.theme === 'dark'"
filled
square
dense
label="Roll"
autocomplete="off"
v-model="custom_rolls[index].roll"
lazy-rules
:rules="[
(val) => !!val || 'Roll is required',
(val) => val.match(/^[0-9]+d[0-9]+(\+[0-9])?$/) || 'Allowed format: 2d6 or 2d6+1',
]"
/>

<hk-dmg-type-select
v-if="roll_type !== 'heal'"
dense
required
v-model="custom_rolls[index].damage_type"
label="Damage type"
class="ml-1"
/>
<hk-dmg-type-select
v-if="roll_type !== 'heal'"
dense
required
v-model="custom_rolls[index].damage_type"
label="Damage type"
class="ml-1"
/>

<a v-if="index > 0" class="remove" @click="removeRoll(index)">
<i aria-hidden="true" class="fas fa-trash-alt" />
</a>
</div>
<a v-if="index > 0" class="remove" @click="removeRoll(index)">
<i aria-hidden="true" class="fas fa-trash-alt" />
</a>
</div>

<hk-roll
v-if="targeted.length > 0"
tooltip="Roll"
tooltipPosition="right"
@roll="roll($event)"
>
<a class="btn btn-block">Roll</a>
</hk-roll>
<div v-else class="text-center text-bold red">Select one ore more targets</div>
</q-form>
<hk-roll
v-if="targeted.length > 0"
tooltip="Roll"
tooltipPosition="right"
class="full-width"
@roll="roll($event)"
>
<span class="btn btn-block">Roll</span>
</hk-roll>
<div v-else class="text-center text-bold red">Select one ore more targets</div>
</div>
</template>

Expand Down
26 changes: 7 additions & 19 deletions src/views/Tools/HomebrewCreation.vue
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,12 @@
His philosophy: "The secret of D&D is: you can create everything yourself"
</p>

<q-img
src="~assets/_img/tools/homebrew-creation/hbc-logo.webp"
alt="Harmless Key DM Screen"
fit="contain"
/>

<h3 class="text-bold mb-1">Adventure creation</h3>
<p>
A three step solution to help you create a one-shot or campaign. We've tried it ourselves and honestly, it was never easier or quicker to fully create a custom one-shot.
Expand Down Expand Up @@ -71,24 +77,6 @@ export default {
.q-img {
display: block;
margin: 30px auto;
width: 100%;
&::v-deep .q-img__content {
> div {
background: none;
}
}
&.res-vul {
width: 50%;
max-width: 300px;
}
&.action {
max-width: 600px;
cursor: pointer;
}
&.small {
max-width: 600px;
border-radius: $border-radius;
}
max-width: 300px;
}
</style>

0 comments on commit ffda1a7

Please sign in to comment.