fix: add missing issuer-service JwtStrategy + fix home search bar overflow

- Add issuer-service/infrastructure/strategies/jwt.strategy.ts (was omitted
  from previous commit, causing build failure)
- Wrap search hint Text in Expanded to prevent Row overflow

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
hailin 2026-03-04 23:11:10 -08:00
parent 5113975c72
commit 9a4c2c1c19
2 changed files with 24 additions and 3 deletions

View File

@ -0,0 +1,18 @@
import { Injectable } from '@nestjs/common';
import { PassportStrategy } from '@nestjs/passport';
import { ExtractJwt, Strategy } from 'passport-jwt';
@Injectable()
export class JwtStrategy extends PassportStrategy(Strategy, 'jwt') {
constructor() {
super({
jwtFromRequest: ExtractJwt.fromAuthHeaderAsBearerToken(),
ignoreExpiration: false,
secretOrKey: process.env.JWT_ACCESS_SECRET || 'dev-access-secret',
});
}
async validate(payload: { sub: string; role: string; kycLevel: number; type: string }) {
return { sub: payload.sub, role: payload.role, kycLevel: payload.kycLevel };
}
}

View File

@ -247,9 +247,12 @@ class _HomePageState extends State<HomePage> {
const SizedBox(width: 14),
const Icon(Icons.search_rounded, size: 20, color: AppColors.textTertiary),
const SizedBox(width: 8),
Text(
Expanded(
child: Text(
context.t('home.searchHint'),
style: AppTypography.bodyMedium.copyWith(color: AppColors.textTertiary),
overflow: TextOverflow.ellipsis,
),
),
],
),