Skip to content

Commit 6117514

Browse files
authored
feat: Enabling new UI by default (#3780)
Signed-off-by: Emre Bogazliyanlioglu <emre@wormholelabs.xyz>
1 parent b3f84c8 commit 6117514

File tree

4 files changed

+5
-9
lines changed

4 files changed

+5
-9
lines changed

src/AppRouter.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ const AppRouterContent = () => {
4343
const prevRoute = usePrevious(route);
4444
const { hasExternalSearch } = useExternalSearch();
4545

46-
const UIRefreshV3Enabled = getExperiment('enableUIRefreshV3');
46+
const UIRefreshV3Enabled = getExperiment('enableUIRefreshV3', true);
4747

4848
useEffect(() => {
4949
const redeemRoute = 'redeem';

src/components/FooterNavBar.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ function itemAppender(acc: MenuItem[], item: MenuEntry) {
2121

2222
function defaultMenuItems(navigate: (name: Route) => void): MenuItem[] {
2323
const items: MenuItem[] = [];
24-
if (!getExperiment('enableUIRefreshV3')) {
24+
if (!getExperiment('enableUIRefreshV3', true)) {
2525
items.push({
2626
label: 'Resume Transaction',
2727
handleClick: () => navigate('search'),

src/components/SampleApp/index.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ import React, { useEffect } from 'react';
33
import { useState } from 'react';
44

55
import WormholeConnect from '../../WormholeConnect';
6-
import config from 'config';
76
import type { WormholeConnectConfig } from 'config/types';
87

98
/*
@@ -48,6 +47,7 @@ import {
4847
cctpV2FastExecutorRoute,
4948
} from 'exports/executor';
5049
import type { WormholeConnectTheme } from 'theme';
50+
import { getExperiment } from 'utils/experiments';
5151

5252
const MAX_URL_SIZE = 30_000; // 30kb (HTTP header limit is set to 32kb)
5353

@@ -396,7 +396,7 @@ function SampleApp() {
396396
<pre>input</pre>
397397
<i>string;</i>
398398
</li>
399-
{config.ui?.experimental?.enableUIRefreshV3 && (
399+
{getExperiment('enableUIRefreshV3', true) && (
400400
<li>
401401
<pre>inputFillTreatment</pre>
402402
<i>boolean;</i>

tests/e2e/config/index.ts

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ const mayanSWIFT = `{
55
network: 'mainnet',
66
coingecko: { customUrl: 'https://coingecko.labsapis.com' },
77
ui: {
8-
experimental: { enableUIRefreshV3: true },
98
showInProgressWidget: true,
109
testOptions: {
1110
enableHeadlessSigner: true,
@@ -20,7 +19,6 @@ const CCTPExecutor = `{
2019
network: 'mainnet',
2120
coingecko: { customUrl: 'https://coingecko.labsapis.com' },
2221
ui: {
23-
experimental: { enableUIRefreshV3: true },
2422
showInProgressWidget: true,
2523
testOptions: {
2624
enableHeadlessSigner: true,
@@ -35,7 +33,6 @@ const CCTPV2Standard = `{
3533
network: 'mainnet',
3634
coingecko: { customUrl: 'https://coingecko.labsapis.com' },
3735
ui: {
38-
experimental: { enableUIRefreshV3: true },
3936
showInProgressWidget: true,
4037
testOptions: {
4138
enableHeadlessSigner: true,
@@ -50,9 +47,8 @@ const NTTRoutes = `{
5047
network: 'mainnet',
5148
coingecko: { customUrl: 'https://coingecko.labsapis.com' },
5249
ui: {
53-
experimental: { enableUIRefreshV3: true },
5450
showInProgressWidget: true,
55-
testOptions: { enableHeadlessSigner: false },
51+
testOptions: { enableHeadlessSigner: true },
5652
},
5753
routes: [
5854
...nttRoutes({

0 commit comments

Comments
 (0)