land on Order page; ui fixes
This commit is contained in:
@@ -153,7 +153,16 @@ export async function connectWallet(chainId) {
|
||||
await updateAccounts(chainId, p)
|
||||
}
|
||||
catch (e) {
|
||||
if (e.reason!=='rejected') {
|
||||
console.log('connectWallet error', e.reason, e)
|
||||
if (e.reason==='rejected') {
|
||||
const ws = useWalletStore();
|
||||
const tx = ws.transaction
|
||||
if (tx) {
|
||||
tx.state = TransactionState.Rejected
|
||||
ws.transaction = null
|
||||
}
|
||||
}
|
||||
else {
|
||||
console.error(e, e.reason)
|
||||
throw e
|
||||
}
|
||||
|
||||
@@ -184,7 +184,8 @@ function initChart() {
|
||||
chart.onIntervalChanged().subscribe(null, changeInterval)
|
||||
chart.onDataLoaded().subscribe(null, dataLoaded)
|
||||
const tzapi = chart.getTimezoneApi();
|
||||
tzapi.onTimezoneChanged().subscribe(null, (tz)=>{if (tz==='exchange') tz='Etc/UTC'; prefs.timezone=tz;})
|
||||
tzapi.onTimezoneChanged().subscribe(null, (tz)=>{if (tz==='exchange') tz='Etc/UTC'; s.timeZone=tz})
|
||||
s.timeZone = tzapi.getTimezone().id
|
||||
// chart.onHoveredSourceChanged().subscribe(null, ()=>console.log('hovered source changed', arguments))
|
||||
// chart.selection().onChanged().subscribe(null, s => console.log('selection', chart.selection().allSources()));
|
||||
const symbolExt = chart.symbolExt();
|
||||
@@ -358,7 +359,7 @@ function doHandleCrosshairMovement(point) {
|
||||
const points = structuredClone(shape.getPoints());
|
||||
const lpbe = shape._model._linePointBeingEdited
|
||||
points[lpbe] = point
|
||||
// console.log('drag calling onPoints', points, shape, lpbe)
|
||||
// console.log('calling onDrag', points, shape)
|
||||
invokeCallbacks(shapeCallbacks[shapeId], 'onDrag', shapeId, shape, points)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -157,6 +157,7 @@ async function placeOrder() {
|
||||
|
||||
async function doPlaceOrder() {
|
||||
console.log('place orders')
|
||||
showWarnings.value = false
|
||||
if (ws.transaction!==null) {
|
||||
console.error('Transaction already in progress')
|
||||
}
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
:set-values="setLines" :set-weights="setWeights"
|
||||
:set-shapes="setShapes"
|
||||
:std-width="stdWidth" :build-tranches="buildTranches">
|
||||
<table>
|
||||
<table v-if="!co.drawing">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td> </td>
|
||||
|
||||
@@ -23,7 +23,8 @@
|
||||
<v-icon icon="mdi-chat-alert-outline" color="grey" class="mr-1"/>
|
||||
Click the chart!
|
||||
</div>
|
||||
<div v-if="rungs>1" class="mx-2 d-flex align-center">
|
||||
<div v-if="rungs>1" class="mx-2 d-flex align-start">
|
||||
<div class="d-flex align-center mt-2">
|
||||
<v-slider v-if="rungs>1" :direction="orientation?'vertical':'horizontal'" min="-100" max="100" v-model="skew100"
|
||||
class="no-slider-bg ml-2 mr-4" hide-details/>
|
||||
<v-text-field type="number" v-model="skew100" min="-100" max="100"
|
||||
@@ -34,6 +35,7 @@
|
||||
</template>
|
||||
</v-text-field>
|
||||
</div>
|
||||
</div>
|
||||
</builder-panel>
|
||||
</template>
|
||||
|
||||
@@ -259,7 +261,7 @@ function translateOnModel(shape) {
|
||||
if (!this.beingDragged())
|
||||
return
|
||||
const prev = getModelValue(oldModel)
|
||||
const cur = vectorize(getModelValue(this.model))
|
||||
const cur = vectorize(getModelValue(model))
|
||||
const delta = vectorSub(cur, prev)
|
||||
// console.log('delta', shape.id, prev, cur, delta)
|
||||
let [a, b] = endpoints.value
|
||||
|
||||
@@ -2,22 +2,6 @@
|
||||
import { createRouter, createWebHistory } from 'vue-router'
|
||||
|
||||
const routes = [
|
||||
{
|
||||
component: () => import('@/corp/CorpLayout.vue'),
|
||||
path:'/home',
|
||||
children: [
|
||||
{
|
||||
name: 'Home',
|
||||
path: '/home',
|
||||
component: () => import('@/corp/Home.vue'),
|
||||
},
|
||||
{
|
||||
name: 'HowItWorks',
|
||||
path: '/home/how-it-works',
|
||||
component: () => import('@/corp/HowItWorks.vue'),
|
||||
},
|
||||
]
|
||||
},
|
||||
{
|
||||
path: '/',
|
||||
component: () => import('@/layouts/chart/ChartLayout.vue'),
|
||||
@@ -28,7 +12,7 @@ const routes = [
|
||||
// route level code-splitting
|
||||
// this generates a separate chunk (about.[hash].js) for this route
|
||||
// which is lazy-loaded when the route is visited.
|
||||
component: () => import('@/components/chart/ChartVault.vue'),
|
||||
component: () => import('@/components/chart/ChartPlaceOrder.vue'),
|
||||
},
|
||||
{
|
||||
name: 'Order',
|
||||
|
||||
Reference in New Issue
Block a user