Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pseudo mod toggle #1373

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1,941 changes: 0 additions & 1,941 deletions main/yarn.lock

This file was deleted.

3 changes: 2 additions & 1 deletion renderer/public/data/en/app_i18n.json
Original file line number Diff line number Diff line change
Expand Up @@ -320,6 +320,7 @@
"auto_search": "Perform an auto search, when pressing",
"select_stock": "Always select \"Stock\" filter",
"show_prediction": "Show price prediction",
"remember_currency": "Remember the Buyout Currency filter"
"remember_currency": "Remember the Buyout Currency filter",
"pseudo": "Use pseudo mods"
}
}
1 change: 1 addition & 0 deletions renderer/src/web/Config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -197,6 +197,7 @@ export const defaultConfig = (): Config => ({
searchStatRange: 10,
showCursor: true,
requestPricePrediction: false,
pseudo:true,
rememberCurrency: false
} as widget.PriceCheckWidget,
{
Expand Down
3 changes: 2 additions & 1 deletion renderer/src/web/price-check/CheckedItem.vue
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,8 @@ export default defineComponent({
currency: widget.value.rememberCurrency || (prevItem &&
item.info.namespace === prevItem.info.namespace &&
item.info.refName === prevItem.info.refName
) ? prevCurrency : undefined
) ? prevCurrency : undefined,
pseudo: widget.value.pseudo
})

if ((!props.advancedCheck && !widget.value.smartInitialSearch) ||
Expand Down
4 changes: 3 additions & 1 deletion renderer/src/web/price-check/filters/create-item-filters.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ interface CreateOptions {
activateStockFilter: boolean
exact: boolean
useEn: boolean
pseudo: boolean
}

export function createFilters (
Expand All @@ -28,7 +29,8 @@ export function createFilters (
listed: undefined,
currency: opts.currency,
league: opts.league,
collapseListings: opts.collapseListings
collapseListings: opts.collapseListings,
pseudo: opts.pseudo
}
}

Expand Down
1 change: 1 addition & 0 deletions renderer/src/web/price-check/filters/create-presets.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ export function createPresets (
activateStockFilter: boolean
searchStatRange: number
useEn: boolean
pseudo: boolean
}
): { presets: FilterPreset[], active: string } {
if (item.info.refName === 'Expedition Logbook') {
Expand Down
6 changes: 5 additions & 1 deletion renderer/src/web/price-check/filters/create-stat-filters.ts
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,7 @@ export function initUiModFilters (
item: ParsedItem,
opts: {
searchStatRange: number
pseudo: boolean
}
): StatFilter[] {
const ctx: FiltersCreationContext = {
Expand All @@ -132,11 +133,14 @@ export function initUiModFilters (

if (item.info.refName !== 'Split Personality') {
filterItemProp(ctx)
filterPseudo(ctx)
//filterPseudo(ctx)
if (item.info.refName === "Emperor's Vigilance") {
filterBasePercentile(ctx)
}
}
if(opts.pseudo){
filterPseudo(ctx)
}

if (!item.isCorrupted && !item.isMirrored) {
ctx.statsByType = ctx.statsByType.filter(mod => mod.type !== ModifierType.Fractured)
Expand Down
1 change: 1 addition & 0 deletions renderer/src/web/price-check/filters/interfaces.ts
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ export interface ItemFilters {
currency: string | undefined
league: string
collapseListings: 'api' | 'app'
pseudo: boolean
}
}

Expand Down
3 changes: 3 additions & 0 deletions renderer/src/web/settings/price-check.vue
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,8 @@
</div>
<ui-checkbox class="mb-4"
v-model="rememberCurrency">{{ t(':remember_currency') }}</ui-checkbox>
<ui-checkbox class="mb-4"
v-model="pseudo">{{ t(':pseudo') }}</ui-checkbox>
<ui-checkbox class="mb-4"
v-model="activateStockFilter">{{ t(':select_stock') }}</ui-checkbox>
<ui-checkbox class="mb-4"
Expand Down Expand Up @@ -131,6 +133,7 @@ export default defineComponent({
smartInitialSearch: configModelValue(() => configWidget.value, 'smartInitialSearch'),
lockedInitialSearch: configModelValue(() => configWidget.value, 'lockedInitialSearch'),
rememberCurrency: configModelValue(() => configWidget.value, 'rememberCurrency'),
pseudo: configModelValue(() => configWidget.value, 'pseudo'),
searchStatRange: computed<number>({
get () {
return configWidget.value.searchStatRange
Expand Down