Skip to content

Commit

Permalink
ci(release): publish latest release
Browse files Browse the repository at this point in the history
  • Loading branch information
hello-happy-puppy committed Aug 8, 2024
1 parent 48a0bb2 commit e3a712f
Show file tree
Hide file tree
Showing 28 changed files with 223 additions and 490 deletions.
9 changes: 7 additions & 2 deletions RELEASE
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
- Onboarding improvements
- Adds fallback support method for opening the side panel on chrome failure
Here are the latest updates:

Native Asset Top Up: Easily access our fiat on ramp feature if you don’t have enough native asset on a network to complete a transaction.

Other changes:

- Various bug fixes and performance improvements
- Improved gas estimation for Send transactions
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
extension/1.2.1
mobile/1.32
149 changes: 0 additions & 149 deletions apps/extension/src/app/PopupApp.tsx

This file was deleted.

40 changes: 1 addition & 39 deletions apps/extension/src/app/navigation/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ export const useExtensionNavigation = (): {
export async function focusOrCreateOnboardingTab(page?: string): Promise<void> {
const extension = await chrome.management.getSelf()

const tabs = await chrome.tabs.query({ url: `chrome-extension://${extension.id}/onboarding.html*` })
const tabs = await chrome.tabs.query({ url: `chrome-extension://${extension.id}/*` })
const tab = tabs[0]

const url = 'onboarding.html#/' + (page ? page : TopLevelRoutes.Onboarding)
Expand Down Expand Up @@ -68,44 +68,6 @@ export async function focusOrCreateOnboardingTab(page?: string): Promise<void> {
})
}

export async function focusOrCreateDappRequestWindow(tabId: number | undefined, windowId: number): Promise<void> {
const extension = await chrome.management.getSelf()

const window = await chrome.windows.getCurrent()

const tabs = await chrome.tabs.query({ url: `chrome-extension://${extension.id}/popup.html*` })
const tab = tabs[0]

// Centering within current window
const height = 410
const width = 330
const top = Math.round((window.top ?? 0) + ((window.height ?? height) - height) / 2)
const left = Math.round((window.left ?? 0) + ((window.width ?? width) - width) / 2)
let url = `popup.html?windowId=${windowId}`
if (tabId) {
url += `&tabId=${tabId}`
}

if (!tab?.id) {
await chrome.windows.create({
url,
type: 'popup',
top,
left,
width,
height,
})
return
}

await chrome.tabs.update(tab.id, {
url,
active: true,
highlighted: true,
})
await chrome.windows.update(tab.windowId, { focused: true, top, left, width, height })
}

/**
* To avoid opening too many tabs while also ensuring that we don't take over the user's active tab,
* we only update the URL of the active tab if it's already in a specific route of the Uniswap interface.
Expand Down
1 change: 0 additions & 1 deletion apps/extension/src/app/sentry.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ export const enum SentryAppNameTag {
Onboarding = 'onboarding',
ContentScript = 'content-script',
Background = 'background',
Popup = 'popup',
}

export function initializeSentry(appNameTag: SentryAppNameTag, sentryUserId: string): void {
Expand Down
5 changes: 0 additions & 5 deletions apps/extension/src/background/utils/chromeSidePanelUtils.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import { focusOrCreateDappRequestWindow } from 'src/app/navigation/utils'
import { logger } from 'utilities/src/logger/logger'

export async function openSidePanel(tabId: number | undefined, windowId: number): Promise<void> {
Expand All @@ -9,10 +8,6 @@ export async function openSidePanel(tabId: number | undefined, windowId: number)
windowId,
})
} catch (error) {
// TODO WALL-4313 - Backup for some broken chrome.sidePanel.open functionality
// Consider removing this once the issue is resolved or leaving as fallback
await focusOrCreateDappRequestWindow(tabId, windowId)

logger.error(error, {
tags: {
file: 'background/background.ts',
Expand Down
2 changes: 1 addition & 1 deletion apps/extension/src/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"manifest_version": 3,
"name": "Uniswap Extension",
"description": "The Uniswap Extension is a self-custody crypto wallet that's built for swapping.",
"version": "1.2.1",
"version": "1.2.0",
"minimum_chrome_version": "116",
"icons": {
"16": "assets/icon16.png",
Expand Down
68 changes: 0 additions & 68 deletions apps/extension/src/popup.html

This file was deleted.

45 changes: 0 additions & 45 deletions apps/extension/src/popup/popup.tsx

This file was deleted.

8 changes: 1 addition & 7 deletions apps/extension/src/store/store.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ const setupStore = (preloadedState?: PreloadedState<ExtensionState>): ReturnType
let store: ReturnType<typeof setupStore> | undefined
let persistor: ReturnType<typeof persistStore> | undefined

export async function initializeReduxStore(args?: { readOnly?: boolean }): Promise<{
export async function initializeReduxStore(): Promise<{
store: ReturnType<typeof setupStore>
persistor: ReturnType<typeof persistStore>
}> {
Expand All @@ -69,12 +69,6 @@ export async function initializeReduxStore(args?: { readOnly?: boolean }): Promi
store = setupStore(oldStore)
persistor = persistStore(store)

if (args?.readOnly) {
// This means the store will be initialized with the persisted state from disk, but it won't persist any changes.
// Only useful for use cases where we don't want to modify the state (for example, a popup window instead of the sidebar).
persistor.pause()
}

// We wait a few seconds to make sure the store is fully initialized and persisted before deleting the old storage.
// This is needed because otherwise the background script might think the user is not onboarded if it reads the storage while it's being migrated.
if (oldStore) {
Expand Down
1 change: 0 additions & 1 deletion apps/extension/webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,6 @@ module.exports = (env) => {
sidebar: './src/sidebar/sidebar.tsx',
injected: './src/contentScript/injected.ts',
ethereum: './src/contentScript/ethereum.ts',
popup: './src/popup/popup.tsx',
},
output: {
filename: '[name].js',
Expand Down
Loading

0 comments on commit e3a712f

Please sign in to comment.