feature/FA-11_CICD #33

Merged
conco merged 27 commits from feature/FA-11_CICD into master 2025-11-26 23:39:45 +00:00
9 changed files with 12 additions and 12 deletions
Showing only changes of commit ba99642e97 - Show all commits

View File

@@ -50,8 +50,8 @@ jobs:
- name: Export schema
run: |
dotnet run --project ${{ matrix.service.project }}/${{ matrix.service.project }}.csproj \
--no-build -c Release --no-launch-profile \
dotnet run -c Release --no-build --no-launch-profile \
--project ${{ matrix.service.project }}/${{ matrix.service.project }}.csproj \
-- schema export --output ${{ matrix.service.project }}/schema.graphql
- name: Pack subgraph

View File

@@ -47,7 +47,7 @@ jobs:
uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
uses: actions/setup-node@v6.0.0
with:
node-version: '20'
cache: 'npm'

View File

@@ -6,7 +6,7 @@ import tseslint from 'typescript-eslint'
import { defineConfig, globalIgnores } from 'eslint/config'
export default defineConfig([
globalIgnores(['dist']),
globalIgnores(['dist', 'src/__generated__']),
{
files: ['**/*.{ts,tsx}'],
extends: [

View File

@@ -6,7 +6,7 @@ const uri = import.meta.env.VITE_GRAPHQL_URI ?? 'https://localhost:5001/graphql'
const httpLink = new HttpLink({ uri })
const authLink = new SetContextLink(async ({ headers }, _) => {
const authLink = new SetContextLink(async ({ headers }) => {
if (!userManager) return { headers }
try {
const user = await userManager.getUser()

View File

@@ -14,12 +14,11 @@ const AuthContext = createContext<AuthContextValue | undefined>(undefined)
export function AuthProvider({ children }: { children: ReactNode }) {
const [user, setUser] = useState<User | null>(null)
const [isLoading, setIsLoading] = useState(true)
const [isLoading, setIsLoading] = useState(!!userManager)
const callbackHandledRef = useRef(false)
useEffect(() => {
if (!userManager) {
setIsLoading(false)
return
}
@@ -121,6 +120,7 @@ export function AuthProvider({ children }: { children: ReactNode }) {
return <AuthContext.Provider value={value}>{children}</AuthContext.Provider>
}
// eslint-disable-next-line react-refresh/only-export-components
export function useAuth() {
const context = useContext(AuthContext)
if (!context) {

View File

@@ -31,4 +31,5 @@ function Badge({ className, variant, ...props }: BadgeProps) {
)
}
// eslint-disable-next-line react-refresh/only-export-components
export { Badge, badgeVariants }

View File

@@ -51,4 +51,5 @@ const Button = React.forwardRef<HTMLButtonElement, ButtonProps>(
)
Button.displayName = 'Button'
// eslint-disable-next-line react-refresh/only-export-components
export { Button, buttonVariants }

View File

@@ -2,8 +2,7 @@ import * as React from 'react'
import { cn } from '../../lib/utils'
export interface InputProps
extends React.InputHTMLAttributes<HTMLInputElement> {}
export type InputProps = React.InputHTMLAttributes<HTMLInputElement>
const Input = React.forwardRef<HTMLInputElement, InputProps>(
({ className, type, ...props }, ref) => {

View File

@@ -13,14 +13,13 @@ export function NovelsPage() {
notifyOnNetworkStatusChange: true,
})
const edges = data?.novels?.edges ?? []
const pageInfo = data?.novels?.pageInfo
const hasNextPage = pageInfo?.hasNextPage ?? false
const endCursor = pageInfo?.endCursor ?? null
const novels = useMemo(
() => edges.map((edge) => edge?.node).filter(Boolean),
[edges]
() => (data?.novels?.edges ?? []).map((edge) => edge?.node).filter(Boolean),
[data?.novels?.edges]
)
async function handleLoadMore() {