Skip to content

Commit

Permalink
Merge branch 'master' into ffxiv-export-url-endings
Browse files Browse the repository at this point in the history
  • Loading branch information
cohenaj194 authored Oct 6, 2024
2 parents eb98ae7 + 50ab3ab commit 31f9626
Show file tree
Hide file tree
Showing 14 changed files with 940 additions and 279 deletions.
54 changes: 53 additions & 1 deletion app/components/FFXIVResults/FullScan/Results.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,27 @@ const cvsFileList: Array<{ title: string; value: keyof ResponseType }> = [
{ title: 'Lowest Price Stack Size', value: 'stack_size' },
{ title: 'Lowest Price Last Update Time', value: 'update_time' },
{ title: 'Universalis Link', value: 'url' },
{ title: 'NPC Vendor Info', value: 'npc_vendor_info' }
{ title: 'NPC Vendor Info', value: 'npc_vendor_info' },
{ title: 'Region Weekly Median NQ', value: 'regionWeeklyMedianNQ' },
{ title: 'Region Weekly Average NQ', value: 'regionWeeklyAverageNQ' },
{
title: 'Region Weekly Sales Amount NQ',
value: 'regionWeeklySalesAmountNQ'
},
{
title: 'Region Weekly Quantity Sold NQ',
value: 'regionWeeklyQuantitySoldNQ'
},
{ title: 'Region Weekly Median HQ', value: 'regionWeeklyMedianHQ' },
{ title: 'Region Weekly Average HQ', value: 'regionWeeklyAverageHQ' },
{
title: 'Region Weekly Sales Amount HQ',
value: 'regionWeeklySalesAmountHQ'
},
{
title: 'Region Weekly Quantity Sold HQ',
value: 'regionWeeklyQuantitySoldHQ'
}
]

const fuzzyFilter: FilterFn<any> = (row, columnId, value, addMeta) => {
Expand Down Expand Up @@ -200,6 +220,38 @@ const Results = ({ rows }: ResultTableProps) => {
cell: (info) => (
<ItemDataLink link={'/queries/item-data/' + info.getValue()} />
)
}),
columnHelper.accessor('regionWeeklyMedianNQ', {
header: 'Region Weekly Median NQ',
cell: (info) => info.getValue().toLocaleString()
}),
columnHelper.accessor('regionWeeklyAverageNQ', {
header: 'Region Weekly Average NQ',
cell: (info) => info.getValue().toLocaleString()
}),
columnHelper.accessor('regionWeeklySalesAmountNQ', {
header: 'Region Weekly Sales Amount NQ',
cell: (info) => info.getValue().toLocaleString()
}),
columnHelper.accessor('regionWeeklyQuantitySoldNQ', {
header: 'Region Weekly Quantity Sold NQ',
cell: (info) => info.getValue().toLocaleString()
}),
columnHelper.accessor('regionWeeklyMedianHQ', {
header: 'Region Weekly Median HQ',
cell: (info) => info.getValue().toLocaleString()
}),
columnHelper.accessor('regionWeeklyAverageHQ', {
header: 'Region Weekly Average HQ',
cell: (info) => info.getValue().toLocaleString()
}),
columnHelper.accessor('regionWeeklySalesAmountHQ', {
header: 'Region Weekly Sales Amount HQ',
cell: (info) => info.getValue().toLocaleString()
}),
columnHelper.accessor('regionWeeklyQuantitySoldHQ', {
header: 'Region Weekly Quantity Sold HQ',
cell: (info) => info.getValue().toLocaleString()
})
]

Expand Down
6 changes: 6 additions & 0 deletions app/components/navigation/sidebar/Sidebar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -343,6 +343,12 @@ const navGroups: Array<{
external: true,
icon: YoutubeIcon
},
{
name: 'Twitter / X',
href: 'https://x.com/SaddlebagE36285',
external: true,
icon: YoutubeIcon
},
{
name: 'blog',
href: '/blog',
Expand Down
10 changes: 9 additions & 1 deletion app/redux/localStorage/ffScanOrderHelpers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,15 @@ export const defaultSortOrder = [
'profit_raw_percent',
'stack_size',
'update_time',
'home_update_time'
'home_update_time',
'regionWeeklyMedianNQ',
'regionWeeklyAverageNQ',
'regionWeeklySalesAmountNQ',
'regionWeeklyQuantitySoldNQ',
'regionWeeklyMedianHQ',
'regionWeeklyAverageHQ',
'regionWeeklySalesAmountHQ',
'regionWeeklyQuantitySoldHQ'
]

export const getFFScanSortOrderInLocalStorage = (): Array<string> => {
Expand Down
59 changes: 37 additions & 22 deletions app/root.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -244,35 +244,50 @@ function App() {
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [])

useEffect(() => {
const timer = setTimeout(() => {
window.requestAnimationFrame(() => {
// Load Google Tag Manager
;(function (w, d, s, l, i) {
w[l] = w[l] || []
w[l].push({ 'gtm.start': new Date().getTime(), event: 'gtm.js' })
var f = d.getElementsByTagName(s)[0],
j = d.createElement(s),
dl = l != 'dataLayer' ? '&l=' + l : ''
j.async = true
j.src = 'https://www.googletagmanager.com/gtm.js?id=' + i + dl
f.parentNode.insertBefore(j, f)
})(window, document, 'script', 'dataLayer', 'GTM-WH4KFG5')

// Load Ezoic script
const script = document.createElement('script')
script.src = '//www.ezojs.com/ezoic/sa.min.js'
script.async = true
document.body.appendChild(script)

script.onload = function () {
window.ezstandalone = window.ezstandalone || {}
ezstandalone.cmd = ezstandalone.cmd || []
ezstandalone.cmd.push(function () {
ezstandalone.define(118, 116)
ezstandalone.refresh()
ezstandalone.enable()
ezstandalone.display()
})
}
})
}, 3000) // Delay of 3000ms (3 second)

return () => clearTimeout(timer)
}, [])

return (
<html lang="en" className={classNames(`h-full`, theme || '')}>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<script
dangerouslySetInnerHTML={{
__html: `(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':
new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],
j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=
'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);
})(window,document,'script','dataLayer','GTM-WH4KFG5');`
}}
/>
<Meta />
<Links />
<EnsureThemeApplied />
<script async src="//www.ezojs.com/ezoic/sa.min.js"></script>
<script
dangerouslySetInnerHTML={{
__html: `window.ezstandalone = window.ezstandalone || {};
ezstandalone.cmd = ezstandalone.cmd || [];
ezstandalone.cmd.push(function() {
ezstandalone.define(118,116);
ezstandalone.refresh();
ezstandalone.enable();
ezstandalone.display();
});`
}}
/>
</head>
<body className={`h-full bg-gray-100 dark:bg-slate-800`}>
<noscript>
Expand Down
47 changes: 43 additions & 4 deletions app/routes/[robots.txt].tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,51 @@ import { LoaderFunction } from '@remix-run/cloudflare'

export const loader: LoaderFunction = () => {
const robotText = `
User-agent: Googlebot
Disallow: /nogooglebot/
Disallow: /build/
User-agent: *
Allow: /
Allow: /ffxiv
Allow: /queries
Allow: /wow
Allow: /blog/*
Allow: /options
Allow: /queries/item-data/*
Allow: /wow/item-data/*
Allow: /ffxiv/itemlist
Allow: /wow/itemlist
Allow: /queries/recommended
Allow: /ffxiv/marketshare/queries
Allow: /ffxiv/craftsim/queries
Allow: /ffxiv/shopping-list
Allow: /queries/listings
Allow: /queries/item-history
Allow: /ffxiv/self-purchase
Allow: /queries/world-comparison
Allow: /undercut
Allow: /price-sniper
Allow: /allagan-data
Allow: /wow/best-deals/recommended
Allow: /wow/upload-timers
Allow: /wow/shopping-list
Allow: /wow/marketshare/recommended
Allow: /wow/shortage-predictor
Allow: /wow/legacy-marketshare
Allow: /wow/price-alert
Allow: /wow/region-undercut
Allow: /wow/full-scan
Allow: /wow/shortages/commodities
Allow: /wow/shortages/single
Allow: /wow/pet-marketshare
Allow: /ffxiv/scrip-exchange
Allow: /ffxiv/extended-history
Disallow: /nogooglebot/
Disallow: /build/
Disallow: /queries/full-scan
Disallow: /ffxiv/marketshare
Disallow: /ffxiv/craftsim/queries
Disallow: /wow/best-deals
Disallow: /wow/export-search
Disallow: /wow/marketshare
Sitemap: https://saddlebagexchange.com/sitemap.xml
`
Expand Down
Loading

0 comments on commit 31f9626

Please sign in to comment.