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

chore: remove old landing page & related components #1151

Merged
merged 1 commit into from
Jun 10, 2024
Merged
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
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
import Link from 'next/link'
import React from 'react'
import { MediaType } from '../../js/types'
import { MediaType } from '../../../js/types'
import {
UserCircleIcon,
TagIcon
} from '@heroicons/react/24/outline'
import { getUploadDateSummary, urlResolver } from '../../js/utils'
import { ATagWrapper } from '../Utils'
import { getUploadDateSummary, urlResolver } from '../../../js/utils'
import { ATagWrapper } from '../../../components/Utils'

export interface PostBodyProps {
destUrl: string
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@
import { useState } from 'react'
import Image from 'next/image'
import clx from 'classnames'
import Card from '../ui/Card/Card'
import TagList from '../media/TagList'
import { MediaWithTags } from '../../js/types'
import { getUploadDateSummary } from '../../js/utils'
import Card from '../../../components/ui/Card/Card'
import TagList from '../../../components/media/TagList'
import { MediaWithTags } from '../../../js/types'
import { getUploadDateSummary } from '../../../js/utils'
import { PostHeader } from './Post'
import { resolver as urlResolver } from '../media/Tag'
import { ATagWrapper } from '../Utils'
import { resolver as urlResolver } from '../../../components/media/Tag'
import { ATagWrapper } from '../../../components/Utils'

const MOBILE_IMAGE_MAX_WIDITH = 600

Expand Down
2 changes: 1 addition & 1 deletion src/app/(default)/components/RecentTags.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { RecentImageCard } from '@/components/home/RecentMediaCard'
import { RecentImageCard } from '@/app/(default)/components/RecentMediaCard'
import { SectionContainer } from './ui/SectionContainer'
import { getMediaForFeedSC } from '@/js/graphql/gql/serverApi'

Expand Down
13 changes: 0 additions & 13 deletions src/components/home/DenseAreas.tsx

This file was deleted.

70 changes: 0 additions & 70 deletions src/components/home/Map.tsx

This file was deleted.

34 changes: 0 additions & 34 deletions src/components/home/RecentMedia.tsx

This file was deleted.

71 changes: 0 additions & 71 deletions src/components/maps/MarkerLayer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -56,62 +56,6 @@ const closeupLayerStyle: LayerProps = {
}
}

const closeupLayerStyleBright: LayerProps = {
...closeupLayerStyle,
id: 'all-markers-bright',
minzoom: 11,
filter: ['==', 'leaf', true],
layout: {
...closeupLayerStyle.layout,
'text-size': ['interpolate', ['linear'], ['zoom'], 8, 14, 14, 15]
},
paint: {
'icon-color': '#ffffff',
'text-halo-blur': 4,
'text-halo-width': 4,
'text-color': '#000000',
'text-halo-color': '#eaeaea'
}
}

const largeAreaLayerStyleBright: LayerProps = {
...closeupLayerStyle,
id: 'area-markers-bright',
minzoom: 8,
maxzoom: 14,
filter: ['all', ['!=', 'leaf', true], ['>', 'totalClimbs', 30], ['<', 'totalClimbs', 500], ['>', 'density', 0.35]],
layout: {
...closeupLayerStyle.layout,
'text-size': ['interpolate', ['linear'], ['zoom'], 8, 14, 14, 15]
},
paint: {
'icon-color': '#ffffff',
'text-halo-blur': 4,
'text-halo-width': 4,
'text-color': '#000000',
'text-halo-color': '#eaeaea'
}
}

const destinationLayerStyleBright: LayerProps = {
...closeupLayerStyle,
id: 'destination-markers-bright',
minzoom: 5,
maxzoom: 8,
filter: ['all', ['!=', 'leaf', true], ['>=', 'totalClimbs', 300], ['>', 'density', 0.5]],
layout: {
...closeupLayerStyle.layout,
'text-size': ['interpolate', ['linear'], ['zoom'], 8, 14, 14, 15]
},
paint: {
'icon-color': '#ffffff',
'text-halo-blur': 4,
'text-halo-width': 4,
'text-color': '#000000',
'text-halo-color': '#eaeaea'
}
}

interface MarkerLayerProps {
geojson: FeatureCollection<GeoJSON.Geometry, Properties> | undefined
}
Expand All @@ -133,21 +77,6 @@ export default function MarkerLayer ({ geojson }: MarkerLayerProps): JSX.Element
)
}

export function MarkerLayer2 ({ geojson }: MarkerLayerProps): JSX.Element | null {
if (geojson == null) return null
return (
<Source
id='areas'
type='geojson'
data={geojson}
>
<Layer {...destinationLayerStyleBright} />
<Layer {...largeAreaLayerStyleBright} />
<Layer {...closeupLayerStyleBright} />
</Source>
)
}

// Important! Pass these IDs to Mapbox GL so that onClick/onHover receives
// the active Geojson object
export const InteractiveLayerIDs = [layerStyle.id, closeupLayerStyle.id] as string[]
72 changes: 0 additions & 72 deletions src/components/ui/FeatureCard/FeatureCard.tsx

This file was deleted.

36 changes: 0 additions & 36 deletions src/components/ui/FeatureCard/FeatureImage.tsx

This file was deleted.

18 changes: 0 additions & 18 deletions src/components/ui/FeatureCard/index.ts

This file was deleted.

Loading
Loading