Skip to content

Commit

Permalink
run prettier
Browse files Browse the repository at this point in the history
Signed-off-by: ryanwolhuter <dev@ryanwolhuter.com>
  • Loading branch information
ryanwolhuter committed Oct 25, 2023
1 parent a9d5fb8 commit 5ed4cd4
Show file tree
Hide file tree
Showing 21 changed files with 1,527 additions and 1,426 deletions.
2 changes: 1 addition & 1 deletion src/components/ModalOsnap.vue
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ const href = computed(() =>
spaceUrl,
spaceName: props.spaceName,
safeAddress: props.treasury.address,
network: props.treasury.network as Network,
network: props.treasury.network as Network
})
);
</script>
Expand Down
16 changes: 9 additions & 7 deletions src/components/SettingsTreasuriesBlockItem.vue
Original file line number Diff line number Diff line change
Expand Up @@ -8,20 +8,22 @@ defineProps<{
}>();
const emit = defineEmits<{
removeTreasury: [index: number]
editTreasury: [index: number]
configureOsnap: [index: number, isEnabled: boolean]
removeTreasury: [index: number];
editTreasury: [index: number];
configureOsnap: [index: number, isEnabled: boolean];
}>();
</script>

<template>
<SettingsTreasuriesBlockItemButton v-for="(treasury, i) in treasuries"
<SettingsTreasuriesBlockItemButton
v-for="(treasury, i) in treasuries"
:key="i"
:treasury="treasury" :treasury-index="i"
:treasury="treasury"
:treasury-index="i"
:is-view-only="!!isViewOnly"
:has-osnap-plugin="hasOsnapPlugin"
@edit-treasury="i => emit('editTreasury', i)"
@remove-treasury="i => emit('removeTreasury', i)"
@configure-osnap="(i, isEnabled) => emit('configureOsnap', i, isEnabled)"
/>
</template>
/>
</template>
6 changes: 0 additions & 6 deletions src/plugins/oSnap/components/HandleOutcome/Template.vue

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@ const oracleUiLink = getOracleUiLink(

<template>
<span>
This proposal was disputed in the Optimistic Oracle. It can only be executed if it passes a vote in the Oracle.
This proposal was disputed in the Optimistic Oracle. It can only be executed
if it passes a vote in the Oracle.
</span>

<div>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
<script setup lang="ts">
</script>
<script setup lang="ts"></script>

<template>
<div>
<p>
Waiting for Snapshot vote counting to conclude.
</p>
<p>Waiting for Snapshot vote counting to conclude.</p>
</div>
</template>
</template>
6 changes: 3 additions & 3 deletions src/plugins/oSnap/components/Input/MethodParameter.vue
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ const inputType = computed(() => {
});
const label = `${props.parameter.name} (${props.parameter.type})`;
const arrayPlaceholder = `E.g. ["text", 123, 0x123]`
const arrayPlaceholder = `E.g. ["text", 123, 0x123]`;
const isInputValid = computed(() => {
if (!isDirty.value) return true;
Expand All @@ -49,7 +49,7 @@ const newValue = ref(props.value);
watch(props.parameter, () => {
newValue.value = '';
isDirty.value = false;
})
});
watch(newValue, () => {
if (isInputValid.value) {
Expand Down Expand Up @@ -110,7 +110,7 @@ function onChange(value: string) {
:model-value="value"
@update:modelValue="onChange($event)"
>
<template #label>{{ label }}</template>
<template #label>{{ label }}</template>
</UiInput>
<UiInput
v-if="inputType === 'number'"
Expand Down
3 changes: 1 addition & 2 deletions src/plugins/oSnap/components/Input/ReadOnly.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
<script setup lang="ts">
</script>
<script setup lang="ts"></script>

<template>
<div
Expand Down
4 changes: 1 addition & 3 deletions src/plugins/oSnap/components/Input/TransactionType.vue
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
<script setup lang="ts">
import {
TransactionType
} from '../../types';
import { TransactionType } from '../../types';
import ModalTransactionType from '../TransactionBuilder/ModalTransactionType.vue';
defineProps<{
Expand Down
8 changes: 2 additions & 6 deletions src/plugins/oSnap/components/TransactionBuilder/ModalSafe.vue
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import networks from '@snapshot-labs/snapshot.js/src/networks.json';
defineProps<{
open: boolean;
safes: GnosisSafe[]
safes: GnosisSafe[];
selected: GnosisSafe | null;
}>();
Expand All @@ -31,11 +31,7 @@ function makeSafeDescription(safe: GnosisSafe) {
<h3>Select Safe</h3>
</template>
<div class="mx-0 my-4 flex flex-col space-y-3 md:mx-4">
<button
v-for="(safe, key) in safes"
:key="key"
@click="select(safe)"
>
<button v-for="(safe, key) in safes" :key="key" @click="select(safe)">
<BaseModalSelectItem
:selected="safe.safeAddress === selected?.safeAddress"
:title="safe.safeName"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,4 +75,3 @@ function updateTransaction() {
</UiInput>
</div>
</template>

Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ function updateTransaction(transaction: TTransaction) {
</script>

<template>
<div class="border-b pb-4 mt-4 first:mt-0">
<div class="mt-4 border-b pb-4 first:mt-0">
<div class="flex items-center justify-between text-[#FF5353]">
<h3 class="text-left text-base">
Transaction {{ transactionIndex + 1 }}
Expand Down
15 changes: 5 additions & 10 deletions src/plugins/oSnap/components/TransactionBuilder/TransferFunds.vue
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,9 @@ const nativeAsset = getNativeAsset(props.network);
const amount = ref(props.transaction.amount ?? '');
const recipient = ref(props.transaction.recipient ?? '');
const tokens = ref<Token[]>([nativeAsset, ...props.tokens]);
const selectedTokenAddress = ref<Token['address']>(props.transaction?.token?.address ?? 'main');
const selectedTokenAddress = ref<Token['address']>(
props.transaction?.token?.address ?? 'main'
);
const selectedToken = computed(
() =>
tokens.value.find(token => token.address === selectedTokenAddress.value) ??
Expand All @@ -40,11 +42,7 @@ const selectedTokenIsNative = computed(
const isTokenModalOpen = ref(false);
function updateTransaction() {
if (
!isBigNumberish(amount.value) ||
!isAddress(recipient.value)
)
return;
if (!isBigNumberish(amount.value) || !isAddress(recipient.value)) return;
try {
const data = selectedTokenIsNative.value
Expand Down Expand Up @@ -104,10 +102,7 @@ watch(selectedTokenAddress, updateTransaction);
</BaseButton>

<div class="space-y-2">
<AddressInput
v-model="recipient"
:label="$t('safeSnap.to')"
/>
<AddressInput v-model="recipient" :label="$t('safeSnap.to')" />
<AmountInput
:key="selectedToken?.decimals"
v-model="amount"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,11 +32,7 @@ const selectedCollectable = computed(() => {
});
function updateTransaction() {
if (
!isAddress(recipient.value) ||
!selectedCollectable.value
)
return;
if (!isAddress(recipient.value) || !selectedCollectable.value) return;
try {
const data = getERC721TokenTransferTransactionData(
Expand Down Expand Up @@ -102,4 +98,3 @@ watch(selectedCollectableAddress, updateTransaction);
:label="$t('safeSnap.to')"
/>
</template>

Loading

0 comments on commit 5ed4cd4

Please sign in to comment.