mirror of
https://github.com/SyncrowIOT/web.git
synced 2025-07-15 17:47:53 +00:00
Compare commits
14 Commits
master
...
SP-1611-in
Author | SHA1 | Date | |
---|---|---|---|
15ee79688d | |||
e5e88385e9 | |||
62d5bbce7e | |||
3c80724c1e | |||
dfb120e7cf | |||
8c3861e83c | |||
b90f25f7b0 | |||
4d51321675 | |||
b5e7776ccb | |||
32938404dd | |||
0cfd58d820 | |||
d4625a8f04 | |||
9f24606613 | |||
e87dffd76b |
@ -1,2 +1,2 @@
|
|||||||
ENV_NAME=production
|
ENV_NAME=production
|
||||||
BASE_URL=https://api.syncrow.me
|
BASE_URL=https://syncrow-staging.azurewebsites.net
|
48
.github/workflows/production.yml
vendored
48
.github/workflows/production.yml
vendored
@ -1,48 +0,0 @@
|
|||||||
name: 🚀 Flutter Web Production Deployment
|
|
||||||
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
branches:
|
|
||||||
- master
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
deploy:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
|
|
||||||
env:
|
|
||||||
AWS_DEFAULT_REGION: me-central-1
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- name: ⬇️ Checkout Code
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
|
|
||||||
- name: 🐢 Set up Node.js 20.x
|
|
||||||
uses: actions/setup-node@v4
|
|
||||||
with:
|
|
||||||
node-version: "20"
|
|
||||||
|
|
||||||
- name: 📦 Install Node.js Dependencies (CDK + TypeScript)
|
|
||||||
run: npm install
|
|
||||||
|
|
||||||
- name: 🐳 Set up Docker Buildx
|
|
||||||
uses: docker/setup-buildx-action@v3
|
|
||||||
|
|
||||||
- name: 🔐 Configure AWS Credentials
|
|
||||||
uses: aws-actions/configure-aws-credentials@v4
|
|
||||||
with:
|
|
||||||
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
|
|
||||||
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
|
|
||||||
aws-region: ${{ env.AWS_DEFAULT_REGION }}
|
|
||||||
|
|
||||||
- name: 🎯 Set up Flutter SDK
|
|
||||||
uses: subosito/flutter-action@v2
|
|
||||||
with:
|
|
||||||
flutter-version: "3.32.1"
|
|
||||||
|
|
||||||
- name: 📦 Install Flutter Dependencies
|
|
||||||
run: flutter pub get
|
|
||||||
|
|
||||||
- name: 🛠️ Run Flutter Build & CDK Deploy
|
|
||||||
run: |
|
|
||||||
chmod +x ./build.sh
|
|
||||||
./build.sh
|
|
4
.gitignore
vendored
4
.gitignore
vendored
@ -42,7 +42,3 @@ app.*.map.json
|
|||||||
/android/app/debug
|
/android/app/debug
|
||||||
/android/app/profile
|
/android/app/profile
|
||||||
/android/app/release
|
/android/app/release
|
||||||
|
|
||||||
node_modules
|
|
||||||
cdk.out
|
|
||||||
web-cdk.out
|
|
@ -24,13 +24,4 @@ samples, guidance on mobile development, and a full API reference.
|
|||||||
|
|
||||||
- run command: `flutter run -d chrome --target=lib/main_dev.dart`
|
- run command: `flutter run -d chrome --target=lib/main_dev.dart`
|
||||||
|
|
||||||
## CDK Deployment
|
|
||||||
|
|
||||||
• Bootstrap CDK (first time only): npx cdk bootstrap aws://482311766496/me-central-1
|
|
||||||
• List available stacks: npx cdk list
|
|
||||||
• Deploy web: npx cdk deploy --require-approval never
|
|
||||||
• View changes before deploy: npx cdk diff
|
|
||||||
• Generate CloudFormation template: npx cdk synth
|
|
||||||
• Destroy infrastructure: npx cdk destroy
|
|
||||||
• Web infrastructure is configured in infrastructure/web-stack.ts
|
|
||||||
• After code changes: build Flutter web app and deploy to hosting service
|
|
||||||
|
4
assets/images/completed_done.svg
Normal file
4
assets/images/completed_done.svg
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
<svg width="50" height="50" viewBox="0 0 50 50" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||||
|
<path d="M37.8033 16.3567C37.2313 15.7848 36.3039 15.7847 35.7318 16.3568L21.5532 30.5353L14.2681 23.2504C13.6962 22.6784 12.7686 22.6783 12.1966 23.2505C11.6246 23.8226 11.6246 24.75 12.1966 25.3221L20.5174 33.6427C20.8034 33.9287 21.1783 34.0717 21.5531 34.0717C21.928 34.0717 22.3029 33.9287 22.5888 33.6426L37.8033 18.4283C38.3754 17.8563 38.3754 16.9288 37.8033 16.3567Z" fill="#023DFE" fill-opacity="0.7"/>
|
||||||
|
<path d="M42.6776 7.32236C37.9558 2.60049 31.6776 0 25 0C18.3223 0 12.0442 2.60049 7.32236 7.32236C2.60039 12.0443 0 18.3224 0 25C0 31.6778 2.60039 37.9559 7.32236 42.6777C12.0441 47.3996 18.3223 50 25 50C31.6777 50 37.9558 47.3996 42.6776 42.6777C47.3995 37.9559 50 31.6778 50 25C50 18.3224 47.3995 12.0443 42.6776 7.32236ZM25 47.0703C12.8304 47.0703 2.92969 37.1696 2.92969 25C2.92969 12.8304 12.8304 2.92969 25 2.92969C37.1696 2.92969 47.0703 12.8304 47.0703 25C47.0703 37.1696 37.1696 47.0703 25 47.0703Z" fill="#023DFE" fill-opacity="0.7"/>
|
||||||
|
</svg>
|
After Width: | Height: | Size: 1.0 KiB |
@ -1,14 +0,0 @@
|
|||||||
#!/usr/bin/env node
|
|
||||||
import 'source-map-support/register';
|
|
||||||
import * as cdk from 'aws-cdk-lib';
|
|
||||||
import { WebStack } from '../infrastructure/web-stack';
|
|
||||||
|
|
||||||
const app = new cdk.App();
|
|
||||||
|
|
||||||
new WebStack(app, 'SyncrowWebStack', {
|
|
||||||
env: {
|
|
||||||
account: process.env.CDK_DEFAULT_ACCOUNT,
|
|
||||||
region: 'me-central-1',
|
|
||||||
},
|
|
||||||
certificateArn: app.node.tryGetContext('certificateArn'),
|
|
||||||
});
|
|
17
build.sh
17
build.sh
@ -1,17 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
set -e
|
|
||||||
|
|
||||||
REGION=${AWS_DEFAULT_REGION:-me-central-1}
|
|
||||||
ACCOUNT_ID=$(aws sts get-caller-identity --query Account --output text)
|
|
||||||
STACK_NAME=SyncrowWebStack
|
|
||||||
CERTIFICATE_ARN="arn:aws:acm:us-east-1:$ACCOUNT_ID:certificate/b3ea57be-9bf0-4c66-8b01-9672ef1e8530"
|
|
||||||
|
|
||||||
echo "🧱 Building Flutter Web for PRODUCTION..."
|
|
||||||
flutter build web --target=lib/main.dart --release
|
|
||||||
|
|
||||||
echo "🚀 Deploying CDK stack..."
|
|
||||||
npx cdk deploy $STACK_NAME \
|
|
||||||
--context certificateArn=$CERTIFICATE_ARN \
|
|
||||||
--require-approval never
|
|
||||||
|
|
||||||
echo "✅ Deployment complete. Access the app at: https://app.syncrow.me"
|
|
@ -1,10 +0,0 @@
|
|||||||
{
|
|
||||||
"hosted-zone:account=482311766496:domainName=syncrow.me:region=us-east-2": {
|
|
||||||
"Id": "/hostedzone/Z02085662NLJECF4DGJV3",
|
|
||||||
"Name": "syncrow.me."
|
|
||||||
},
|
|
||||||
"hosted-zone:account=482311766496:domainName=syncrow.me:region=me-central-1": {
|
|
||||||
"Id": "/hostedzone/Z02085662NLJECF4DGJV3",
|
|
||||||
"Name": "syncrow.me."
|
|
||||||
}
|
|
||||||
}
|
|
63
cdk.json
63
cdk.json
@ -1,63 +0,0 @@
|
|||||||
{
|
|
||||||
"app": "npx ts-node --prefer-ts-exts bin/web-stack.ts",
|
|
||||||
"watch": {
|
|
||||||
"include": [
|
|
||||||
"**"
|
|
||||||
],
|
|
||||||
"exclude": [
|
|
||||||
"README.md",
|
|
||||||
"cdk*.json",
|
|
||||||
"**/*.d.ts",
|
|
||||||
"**/*.js",
|
|
||||||
"tsconfig.json",
|
|
||||||
"package*.json",
|
|
||||||
"yarn.lock",
|
|
||||||
"node_modules",
|
|
||||||
"test"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"context": {
|
|
||||||
"@aws-cdk/aws-lambda:recognizeLayerVersion": true,
|
|
||||||
"@aws-cdk/core:checkSecretUsage": true,
|
|
||||||
"@aws-cdk/core:target-partitions": [
|
|
||||||
"aws",
|
|
||||||
"aws-cn"
|
|
||||||
],
|
|
||||||
"@aws-cdk-containers/ecs-service-extensions:enableDefaultLogDriver": true,
|
|
||||||
"@aws-cdk/aws-ec2:uniqueImdsv2TemplateName": true,
|
|
||||||
"@aws-cdk/aws-ecs:arnFormatIncludesClusterName": true,
|
|
||||||
"@aws-cdk/aws-iam:minimizePolicies": true,
|
|
||||||
"@aws-cdk/core:validateSnapshotRemovalPolicy": true,
|
|
||||||
"@aws-cdk/aws-codepipeline:crossAccountKeyAliasStackSafeResourceName": true,
|
|
||||||
"@aws-cdk/aws-s3:createDefaultLoggingPolicy": true,
|
|
||||||
"@aws-cdk/aws-sns-subscriptions:restrictSqsDescryption": true,
|
|
||||||
"@aws-cdk/aws-apigateway:disableCloudWatchRole": true,
|
|
||||||
"@aws-cdk/core:enablePartitionLiterals": true,
|
|
||||||
"@aws-cdk/aws-events:eventsTargetQueueSameAccount": true,
|
|
||||||
"@aws-cdk/aws-iam:standardizedServicePrincipals": true,
|
|
||||||
"@aws-cdk/aws-ecs:disableExplicitDeploymentControllerForCircuitBreaker": true,
|
|
||||||
"@aws-cdk/aws-iam:importedRoleStackSafeDefaultPolicyName": true,
|
|
||||||
"@aws-cdk/aws-s3:serverAccessLogsUseBucketPolicy": true,
|
|
||||||
"@aws-cdk/aws-route53-patters:useCertificate": true,
|
|
||||||
"@aws-cdk/customresources:installLatestAwsSdkDefault": false,
|
|
||||||
"@aws-cdk/aws-rds:databaseProxyUniqueResourceName": true,
|
|
||||||
"@aws-cdk/aws-codedeploy:removeAlarmsFromDeploymentGroup": true,
|
|
||||||
"@aws-cdk/aws-apigateway:authorizerChangeDeploymentLogicalId": true,
|
|
||||||
"@aws-cdk/aws-ec2:launchTemplateDefaultUserData": true,
|
|
||||||
"@aws-cdk/aws-secretsmanager:useAttachedSecretResourcePolicyForSecretTargetAttachments": true,
|
|
||||||
"@aws-cdk/aws-redshift:columnId": true,
|
|
||||||
"@aws-cdk/aws-stepfunctions-tasks:enableLogging": true,
|
|
||||||
"@aws-cdk/aws-ec2:restrictDefaultSecurityGroup": true,
|
|
||||||
"@aws-cdk/aws-apigateway:requestValidatorUniqueId": true,
|
|
||||||
"@aws-cdk/aws-kms:aliasNameRef": true,
|
|
||||||
"@aws-cdk/aws-autoscaling:generateLaunchTemplateInsteadOfLaunchConfig": true,
|
|
||||||
"@aws-cdk/core:includePrefixInUniqueNameGeneration": true,
|
|
||||||
"@aws-cdk/aws-efs:denyAnonymousAccess": true,
|
|
||||||
"@aws-cdk/aws-opensearchservice:enableLogging": true,
|
|
||||||
"@aws-cdk/aws-nordicapis-apigateway:authorizerChangeDeploymentLogicalId": true,
|
|
||||||
"@aws-cdk/aws-ec2:ebsDefaultGp3Volume": true,
|
|
||||||
"@aws-cdk/aws-ecs-patterns:removeDefaultDesiredCount": true,
|
|
||||||
"@aws-cdk/aws-rds:preventRenderingDeprecatedCredentials": true,
|
|
||||||
"@aws-cdk/aws-codepipeline-actions:useNewDefaultBranchForSourceAction": true
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,123 +0,0 @@
|
|||||||
import * as cdk from "aws-cdk-lib";
|
|
||||||
import * as acm from "aws-cdk-lib/aws-certificatemanager";
|
|
||||||
import * as cloudfront from "aws-cdk-lib/aws-cloudfront";
|
|
||||||
import * as origins from "aws-cdk-lib/aws-cloudfront-origins";
|
|
||||||
import * as route53 from "aws-cdk-lib/aws-route53";
|
|
||||||
import * as targets from "aws-cdk-lib/aws-route53-targets";
|
|
||||||
import * as s3 from "aws-cdk-lib/aws-s3";
|
|
||||||
import * as s3deploy from "aws-cdk-lib/aws-s3-deployment";
|
|
||||||
import { Construct } from "constructs";
|
|
||||||
|
|
||||||
export interface WebStackProps extends cdk.StackProps {
|
|
||||||
certificateArn?: string;
|
|
||||||
}
|
|
||||||
|
|
||||||
export class WebStack extends cdk.Stack {
|
|
||||||
public readonly distributionUrl: string;
|
|
||||||
public readonly bucketName: string;
|
|
||||||
|
|
||||||
constructor(scope: Construct, id: string, props?: WebStackProps) {
|
|
||||||
super(scope, id, props);
|
|
||||||
|
|
||||||
const bucketName = `syncrow-web-${this.account}-${this.region}`;
|
|
||||||
|
|
||||||
const webBucket = new s3.Bucket(this, "SyncrowWebBucket", {
|
|
||||||
bucketName,
|
|
||||||
websiteIndexDocument: "index.html",
|
|
||||||
websiteErrorDocument: "index.html",
|
|
||||||
publicReadAccess: true,
|
|
||||||
blockPublicAccess: s3.BlockPublicAccess.BLOCK_ACLS,
|
|
||||||
removalPolicy: cdk.RemovalPolicy.DESTROY,
|
|
||||||
autoDeleteObjects: true,
|
|
||||||
});
|
|
||||||
|
|
||||||
// Use existing wildcard certificate in us-east-1 (required for CloudFront)
|
|
||||||
const webCertificate = props?.certificateArn
|
|
||||||
? acm.Certificate.fromCertificateArn(
|
|
||||||
this,
|
|
||||||
"WildcardCertificate",
|
|
||||||
props.certificateArn
|
|
||||||
)
|
|
||||||
: acm.Certificate.fromCertificateArn(
|
|
||||||
this,
|
|
||||||
"WildcardCertificate",
|
|
||||||
"arn:aws:acm:us-east-1:482311766496:certificate/b3ea57be-9bf0-4c66-8b01-9672ef1e8530"
|
|
||||||
);
|
|
||||||
|
|
||||||
// Get the hosted zone
|
|
||||||
const hostedZone = route53.HostedZone.fromLookup(this, "SyncrowZone", {
|
|
||||||
domainName: "syncrow.me",
|
|
||||||
});
|
|
||||||
|
|
||||||
const distribution = new cloudfront.Distribution(
|
|
||||||
this,
|
|
||||||
"SyncrowWebDistribution",
|
|
||||||
{
|
|
||||||
defaultBehavior: {
|
|
||||||
origin: new origins.S3Origin(webBucket),
|
|
||||||
viewerProtocolPolicy:
|
|
||||||
cloudfront.ViewerProtocolPolicy.REDIRECT_TO_HTTPS,
|
|
||||||
cachePolicy: cloudfront.CachePolicy.CACHING_OPTIMIZED,
|
|
||||||
},
|
|
||||||
domainNames: ["app.syncrow.me"],
|
|
||||||
certificate: webCertificate,
|
|
||||||
defaultRootObject: "index.html",
|
|
||||||
errorResponses: [
|
|
||||||
{
|
|
||||||
httpStatus: 404,
|
|
||||||
responseHttpStatus: 200,
|
|
||||||
responsePagePath: "/index.html",
|
|
||||||
},
|
|
||||||
{
|
|
||||||
httpStatus: 403,
|
|
||||||
responseHttpStatus: 200,
|
|
||||||
responsePagePath: "/index.html",
|
|
||||||
},
|
|
||||||
],
|
|
||||||
}
|
|
||||||
);
|
|
||||||
|
|
||||||
// Create Route 53 record for app.syncrow.me
|
|
||||||
new route53.ARecord(this, "WebAliasRecord", {
|
|
||||||
zone: hostedZone,
|
|
||||||
recordName: "app",
|
|
||||||
target: route53.RecordTarget.fromAlias(
|
|
||||||
new targets.CloudFrontTarget(distribution)
|
|
||||||
),
|
|
||||||
});
|
|
||||||
|
|
||||||
new s3deploy.BucketDeployment(this, "SyncrowWebDeployment", {
|
|
||||||
sources: [s3deploy.Source.asset("./build/web")],
|
|
||||||
destinationBucket: webBucket,
|
|
||||||
distribution,
|
|
||||||
distributionPaths: ["/*"],
|
|
||||||
});
|
|
||||||
|
|
||||||
this.distributionUrl = "https://app.syncrow.me";
|
|
||||||
this.bucketName = bucketName;
|
|
||||||
|
|
||||||
new cdk.CfnOutput(this, "WebsiteUrl", {
|
|
||||||
value: this.distributionUrl,
|
|
||||||
description: "Web Application URL",
|
|
||||||
exportName: `${this.stackName}-WebsiteUrl`,
|
|
||||||
});
|
|
||||||
|
|
||||||
new cdk.CfnOutput(this, "CloudFrontUrl", {
|
|
||||||
value: `https://${distribution.distributionDomainName}`,
|
|
||||||
description: "CloudFront Distribution URL",
|
|
||||||
exportName: `${this.stackName}-CloudFrontUrl`,
|
|
||||||
});
|
|
||||||
|
|
||||||
new cdk.CfnOutput(this, "BucketName", {
|
|
||||||
value: this.bucketName,
|
|
||||||
description: "S3 Bucket Name",
|
|
||||||
exportName: `${this.stackName}-BucketName`,
|
|
||||||
});
|
|
||||||
|
|
||||||
new cdk.CfnOutput(this, "WildcardCertificateArn", {
|
|
||||||
value: webCertificate.certificateArn,
|
|
||||||
description: "Wildcard SSL Certificate ARN (us-east-1)",
|
|
||||||
exportName: `${this.stackName}-WildcardCertificateArn`,
|
|
||||||
});
|
|
||||||
}
|
|
||||||
}
|
|
@ -57,6 +57,16 @@ class Status {
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Status copyWith({
|
||||||
|
String? code,
|
||||||
|
dynamic value,
|
||||||
|
}) {
|
||||||
|
return Status(
|
||||||
|
code: code ?? this.code,
|
||||||
|
value: value ?? this.value,
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
factory Status.fromJson(String source) => Status.fromMap(json.decode(source));
|
factory Status.fromJson(String source) => Status.fromMap(json.decode(source));
|
||||||
|
|
||||||
String toJson() => json.encode(toMap());
|
String toJson() => json.encode(toMap());
|
||||||
|
@ -4,6 +4,7 @@ import 'package:syncrow_web/pages/device_managment/curtain_module/bloc/curtain_m
|
|||||||
import 'package:syncrow_web/pages/device_managment/curtain_module/widgets/accurate_dialog_widget.dart';
|
import 'package:syncrow_web/pages/device_managment/curtain_module/widgets/accurate_dialog_widget.dart';
|
||||||
import 'package:syncrow_web/pages/device_managment/curtain_module/widgets/calibrate_completed_dialog.dart';
|
import 'package:syncrow_web/pages/device_managment/curtain_module/widgets/calibrate_completed_dialog.dart';
|
||||||
import 'package:syncrow_web/pages/device_managment/curtain_module/widgets/normal_text_body_for_dialog.dart';
|
import 'package:syncrow_web/pages/device_managment/curtain_module/widgets/normal_text_body_for_dialog.dart';
|
||||||
|
import 'package:syncrow_web/utils/color_manager.dart';
|
||||||
|
|
||||||
class AccurteCalibratingDialog extends StatelessWidget {
|
class AccurteCalibratingDialog extends StatelessWidget {
|
||||||
final String deviceId;
|
final String deviceId;
|
||||||
@ -17,6 +18,7 @@ class AccurteCalibratingDialog extends StatelessWidget {
|
|||||||
@override
|
@override
|
||||||
Widget build(_) {
|
Widget build(_) {
|
||||||
return AlertDialog(
|
return AlertDialog(
|
||||||
|
backgroundColor: ColorsManager.whiteColors,
|
||||||
contentPadding: EdgeInsets.zero,
|
contentPadding: EdgeInsets.zero,
|
||||||
content: AccurateDialogWidget(
|
content: AccurateDialogWidget(
|
||||||
title: 'Calibrating',
|
title: 'Calibrating',
|
||||||
|
@ -2,6 +2,7 @@ import 'package:flutter/material.dart';
|
|||||||
import 'package:syncrow_web/pages/device_managment/curtain_module/widgets/accurate_calibrating_dialog.dart';
|
import 'package:syncrow_web/pages/device_managment/curtain_module/widgets/accurate_calibrating_dialog.dart';
|
||||||
import 'package:syncrow_web/pages/device_managment/curtain_module/widgets/accurate_dialog_widget.dart';
|
import 'package:syncrow_web/pages/device_managment/curtain_module/widgets/accurate_dialog_widget.dart';
|
||||||
import 'package:syncrow_web/pages/device_managment/curtain_module/widgets/normal_text_body_for_dialog.dart';
|
import 'package:syncrow_web/pages/device_managment/curtain_module/widgets/normal_text_body_for_dialog.dart';
|
||||||
|
import 'package:syncrow_web/utils/color_manager.dart';
|
||||||
|
|
||||||
class AccurateCalibrationDialog extends StatelessWidget {
|
class AccurateCalibrationDialog extends StatelessWidget {
|
||||||
final String deviceId;
|
final String deviceId;
|
||||||
@ -15,6 +16,7 @@ class AccurateCalibrationDialog extends StatelessWidget {
|
|||||||
@override
|
@override
|
||||||
Widget build(_) {
|
Widget build(_) {
|
||||||
return AlertDialog(
|
return AlertDialog(
|
||||||
|
backgroundColor: ColorsManager.whiteColors,
|
||||||
contentPadding: EdgeInsets.zero,
|
contentPadding: EdgeInsets.zero,
|
||||||
content: AccurateDialogWidget(
|
content: AccurateDialogWidget(
|
||||||
title: 'Accurate Calibration',
|
title: 'Accurate Calibration',
|
||||||
|
@ -22,6 +22,7 @@ class AccurateDialogWidget extends StatelessWidget {
|
|||||||
child: Column(
|
child: Column(
|
||||||
children: [
|
children: [
|
||||||
Expanded(
|
Expanded(
|
||||||
|
flex: 3,
|
||||||
child: Column(
|
child: Column(
|
||||||
children: [
|
children: [
|
||||||
Padding(
|
Padding(
|
||||||
@ -43,17 +44,22 @@ class AccurateDialogWidget extends StatelessWidget {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
Expanded(
|
Expanded(
|
||||||
|
flex: 5,
|
||||||
child: body,
|
child: body,
|
||||||
),
|
),
|
||||||
Expanded(
|
Expanded(
|
||||||
|
flex: 2,
|
||||||
child: Column(
|
child: Column(
|
||||||
mainAxisAlignment: MainAxisAlignment.end,
|
mainAxisAlignment: MainAxisAlignment.end,
|
||||||
children: [
|
children: [
|
||||||
const Divider(),
|
const Expanded(child: Divider()),
|
||||||
Row(
|
Row(
|
||||||
children: [
|
children: [
|
||||||
Expanded(
|
Expanded(
|
||||||
child: InkWell(
|
child: InkWell(
|
||||||
|
borderRadius: const BorderRadius.only(
|
||||||
|
bottomLeft: Radius.circular(26),
|
||||||
|
),
|
||||||
onTap: leftOnTap,
|
onTap: leftOnTap,
|
||||||
child: Container(
|
child: Container(
|
||||||
height: 40,
|
height: 40,
|
||||||
@ -64,6 +70,9 @@ class AccurateDialogWidget extends StatelessWidget {
|
|||||||
color: ColorsManager.grayBorder,
|
color: ColorsManager.grayBorder,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
borderRadius: BorderRadius.only(
|
||||||
|
bottomLeft: Radius.circular(26),
|
||||||
|
),
|
||||||
),
|
),
|
||||||
child: const Text(
|
child: const Text(
|
||||||
'Cancel',
|
'Cancel',
|
||||||
@ -74,6 +83,9 @@ class AccurateDialogWidget extends StatelessWidget {
|
|||||||
),
|
),
|
||||||
Expanded(
|
Expanded(
|
||||||
child: InkWell(
|
child: InkWell(
|
||||||
|
borderRadius: const BorderRadius.only(
|
||||||
|
bottomRight: Radius.circular(26),
|
||||||
|
),
|
||||||
onTap: rightOnTap,
|
onTap: rightOnTap,
|
||||||
child: Container(
|
child: Container(
|
||||||
height: 40,
|
height: 40,
|
||||||
@ -84,6 +96,9 @@ class AccurateDialogWidget extends StatelessWidget {
|
|||||||
color: ColorsManager.grayBorder,
|
color: ColorsManager.grayBorder,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
borderRadius: BorderRadius.only(
|
||||||
|
bottomRight: Radius.circular(26),
|
||||||
|
),
|
||||||
),
|
),
|
||||||
child: const Text(
|
child: const Text(
|
||||||
'Next',
|
'Next',
|
||||||
|
@ -28,7 +28,7 @@ class NormalTextBodyForDialog extends StatelessWidget {
|
|||||||
title,
|
title,
|
||||||
style: const TextStyle(
|
style: const TextStyle(
|
||||||
color: ColorsManager.grayColor,
|
color: ColorsManager.grayColor,
|
||||||
fontSize: 17,
|
fontSize: 15,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
@ -42,7 +42,7 @@ class NormalTextBodyForDialog extends StatelessWidget {
|
|||||||
const Text('1. ',
|
const Text('1. ',
|
||||||
style: TextStyle(
|
style: TextStyle(
|
||||||
color: ColorsManager.grayColor,
|
color: ColorsManager.grayColor,
|
||||||
fontSize: 17,
|
fontSize: 15,
|
||||||
)),
|
)),
|
||||||
SizedBox(
|
SizedBox(
|
||||||
width: 450,
|
width: 450,
|
||||||
@ -50,7 +50,7 @@ class NormalTextBodyForDialog extends StatelessWidget {
|
|||||||
step1,
|
step1,
|
||||||
style: const TextStyle(
|
style: const TextStyle(
|
||||||
color: ColorsManager.grayColor,
|
color: ColorsManager.grayColor,
|
||||||
fontSize: 17,
|
fontSize: 15,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
@ -67,13 +67,13 @@ class NormalTextBodyForDialog extends StatelessWidget {
|
|||||||
const Text('2. ',
|
const Text('2. ',
|
||||||
style: TextStyle(
|
style: TextStyle(
|
||||||
color: ColorsManager.grayColor,
|
color: ColorsManager.grayColor,
|
||||||
fontSize: 17,
|
fontSize: 15,
|
||||||
)),
|
)),
|
||||||
Text(
|
Text(
|
||||||
step2,
|
step2,
|
||||||
style: const TextStyle(
|
style: const TextStyle(
|
||||||
color: ColorsManager.grayColor,
|
color: ColorsManager.grayColor,
|
||||||
fontSize: 17,
|
fontSize: 15,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
|
@ -63,6 +63,7 @@ class _QuickCalibratingDialogState extends State<QuickCalibratingDialog> {
|
|||||||
@override
|
@override
|
||||||
Widget build(_) {
|
Widget build(_) {
|
||||||
return AlertDialog(
|
return AlertDialog(
|
||||||
|
backgroundColor: ColorsManager.whiteColors,
|
||||||
contentPadding: EdgeInsets.zero,
|
contentPadding: EdgeInsets.zero,
|
||||||
content: AccurateDialogWidget(
|
content: AccurateDialogWidget(
|
||||||
title: 'Calibrating',
|
title: 'Calibrating',
|
||||||
@ -71,7 +72,7 @@ class _QuickCalibratingDialogState extends State<QuickCalibratingDialog> {
|
|||||||
children: [
|
children: [
|
||||||
const Expanded(
|
const Expanded(
|
||||||
child: Align(
|
child: Align(
|
||||||
alignment: Alignment.center,
|
alignment: Alignment.topCenter,
|
||||||
child: Padding(
|
child: Padding(
|
||||||
padding: EdgeInsets.only(right: 75),
|
padding: EdgeInsets.only(right: 75),
|
||||||
child: Text(
|
child: Text(
|
||||||
@ -85,17 +86,21 @@ class _QuickCalibratingDialogState extends State<QuickCalibratingDialog> {
|
|||||||
child: Align(
|
child: Align(
|
||||||
alignment: Alignment.center,
|
alignment: Alignment.center,
|
||||||
child: Container(
|
child: Container(
|
||||||
width: 110,
|
width: 130,
|
||||||
padding: const EdgeInsets.all(5),
|
padding: const EdgeInsets.all(5),
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
color: ColorsManager.whiteColors,
|
color: ColorsManager.neutralGray.withValues(
|
||||||
|
alpha: 0.5,
|
||||||
|
),
|
||||||
borderRadius: BorderRadius.circular(12),
|
borderRadius: BorderRadius.circular(12),
|
||||||
),
|
),
|
||||||
child: Row(
|
child: Row(
|
||||||
crossAxisAlignment: CrossAxisAlignment.center,
|
crossAxisAlignment: CrossAxisAlignment.center,
|
||||||
children: [
|
children: [
|
||||||
Expanded(
|
Expanded(
|
||||||
child: NumberInputField(controller: _controller),
|
child: Padding(
|
||||||
|
padding: const EdgeInsetsGeometry.only(left: 5),
|
||||||
|
child: NumberInputField(controller: _controller)),
|
||||||
),
|
),
|
||||||
Expanded(
|
Expanded(
|
||||||
child: Text(
|
child: Text(
|
||||||
@ -127,7 +132,7 @@ class _QuickCalibratingDialogState extends State<QuickCalibratingDialog> {
|
|||||||
),
|
),
|
||||||
const Expanded(
|
const Expanded(
|
||||||
child: Align(
|
child: Align(
|
||||||
alignment: Alignment.center,
|
alignment: Alignment.bottomCenter,
|
||||||
child: Text(
|
child: Text(
|
||||||
'2.click Next to Complete the calibration',
|
'2.click Next to Complete the calibration',
|
||||||
style: TextStyle(color: ColorsManager.lightGrayColor),
|
style: TextStyle(color: ColorsManager.lightGrayColor),
|
||||||
|
@ -2,6 +2,7 @@ import 'package:flutter/material.dart';
|
|||||||
import 'package:syncrow_web/pages/device_managment/curtain_module/widgets/accurate_dialog_widget.dart';
|
import 'package:syncrow_web/pages/device_managment/curtain_module/widgets/accurate_dialog_widget.dart';
|
||||||
import 'package:syncrow_web/pages/device_managment/curtain_module/widgets/normal_text_body_for_dialog.dart';
|
import 'package:syncrow_web/pages/device_managment/curtain_module/widgets/normal_text_body_for_dialog.dart';
|
||||||
import 'package:syncrow_web/pages/device_managment/curtain_module/widgets/quick_calibrating_dialog.dart';
|
import 'package:syncrow_web/pages/device_managment/curtain_module/widgets/quick_calibrating_dialog.dart';
|
||||||
|
import 'package:syncrow_web/utils/color_manager.dart';
|
||||||
|
|
||||||
class QuickCalibrationDialog extends StatelessWidget {
|
class QuickCalibrationDialog extends StatelessWidget {
|
||||||
final int timControl;
|
final int timControl;
|
||||||
@ -17,6 +18,7 @@ class QuickCalibrationDialog extends StatelessWidget {
|
|||||||
@override
|
@override
|
||||||
Widget build(_) {
|
Widget build(_) {
|
||||||
return AlertDialog(
|
return AlertDialog(
|
||||||
|
backgroundColor: ColorsManager.whiteColors,
|
||||||
contentPadding: EdgeInsets.zero,
|
contentPadding: EdgeInsets.zero,
|
||||||
content: AccurateDialogWidget(
|
content: AccurateDialogWidget(
|
||||||
title: 'Quick Calibration',
|
title: 'Quick Calibration',
|
||||||
|
@ -286,11 +286,20 @@ class ScheduleBloc extends Bloc<ScheduleEvent, ScheduleState> {
|
|||||||
try {
|
try {
|
||||||
if (state is ScheduleLoaded) {
|
if (state is ScheduleLoaded) {
|
||||||
final dateTime = DateTime.parse(event.time);
|
final dateTime = DateTime.parse(event.time);
|
||||||
|
Status status = Status(code: '', value: '');
|
||||||
|
if (event.category == 'CUR_2') {
|
||||||
|
status = status.copyWith(
|
||||||
|
code: 'control',
|
||||||
|
value: event.functionOn == true ? 'open' : 'close');
|
||||||
|
} else {
|
||||||
|
status =
|
||||||
|
status.copyWith(code: event.category, value: event.functionOn);
|
||||||
|
}
|
||||||
final updatedSchedule = ScheduleEntry(
|
final updatedSchedule = ScheduleEntry(
|
||||||
scheduleId: event.scheduleId,
|
scheduleId: event.scheduleId,
|
||||||
category: event.category,
|
category: event.category,
|
||||||
time: getTimeStampWithoutSeconds(dateTime).toString(),
|
time: getTimeStampWithoutSeconds(dateTime).toString(),
|
||||||
function: Status(code: event.category, value: event.functionOn),
|
function: status,
|
||||||
days: event.selectedDays,
|
days: event.selectedDays,
|
||||||
);
|
);
|
||||||
final success = await DevicesManagementApi().editScheduleRecord(
|
final success = await DevicesManagementApi().editScheduleRecord(
|
||||||
|
@ -52,9 +52,12 @@ class BuildScheduleView extends StatelessWidget {
|
|||||||
children: [
|
children: [
|
||||||
const ScheduleHeader(),
|
const ScheduleHeader(),
|
||||||
const SizedBox(height: 20),
|
const SizedBox(height: 20),
|
||||||
ScheduleModeSelector(
|
if (category == 'CUR_2')
|
||||||
currentMode: state.scheduleMode,
|
const SizedBox()
|
||||||
),
|
else
|
||||||
|
ScheduleModeSelector(
|
||||||
|
currentMode: state.scheduleMode,
|
||||||
|
),
|
||||||
const SizedBox(height: 20),
|
const SizedBox(height: 20),
|
||||||
if (state.scheduleMode == ScheduleModes.schedule)
|
if (state.scheduleMode == ScheduleModes.schedule)
|
||||||
ScheduleManagementUI(
|
ScheduleManagementUI(
|
||||||
|
@ -212,12 +212,20 @@ class _ScheduleTableView extends StatelessWidget {
|
|||||||
isEdit: true,
|
isEdit: true,
|
||||||
).then((updatedSchedule) {
|
).then((updatedSchedule) {
|
||||||
if (updatedSchedule != null) {
|
if (updatedSchedule != null) {
|
||||||
|
bool temp;
|
||||||
|
if (schedule.category == 'CUR_2') {
|
||||||
|
updatedSchedule.function.value == 'open'
|
||||||
|
? temp = true
|
||||||
|
: temp = false;
|
||||||
|
} else {
|
||||||
|
temp = updatedSchedule.function.value;
|
||||||
|
}
|
||||||
context.read<ScheduleBloc>().add(
|
context.read<ScheduleBloc>().add(
|
||||||
ScheduleEditEvent(
|
ScheduleEditEvent(
|
||||||
scheduleId: schedule.scheduleId,
|
scheduleId: schedule.scheduleId,
|
||||||
category: schedule.category,
|
category: schedule.category,
|
||||||
time: updatedSchedule.time,
|
time: updatedSchedule.time,
|
||||||
functionOn: updatedSchedule.function.value,
|
functionOn: temp,
|
||||||
selectedDays: updatedSchedule.days),
|
selectedDays: updatedSchedule.days),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
@ -455,7 +455,7 @@ class UsersBloc extends Bloc<UsersEvent, UsersState> {
|
|||||||
Future<void> checkEmail(
|
Future<void> checkEmail(
|
||||||
CheckEmailEvent event, Emitter<UsersState> emit) async {
|
CheckEmailEvent event, Emitter<UsersState> emit) async {
|
||||||
emit(UsersLoadingState());
|
emit(UsersLoadingState());
|
||||||
String? res = await UserPermissionApi().checkEmail(
|
String? res = await UserPermissionApi().checkEmail(
|
||||||
emailController.text,
|
emailController.text,
|
||||||
);
|
);
|
||||||
checkEmailValid = res!;
|
checkEmailValid = res!;
|
||||||
|
@ -34,7 +34,8 @@ class _AddNewUserDialogState extends State<AddNewUserDialog> {
|
|||||||
return Dialog(
|
return Dialog(
|
||||||
child: Container(
|
child: Container(
|
||||||
decoration: const BoxDecoration(
|
decoration: const BoxDecoration(
|
||||||
color: Colors.white, borderRadius: BorderRadius.all(Radius.circular(20))),
|
color: Colors.white,
|
||||||
|
borderRadius: BorderRadius.all(Radius.circular(20))),
|
||||||
width: 900,
|
width: 900,
|
||||||
child: Column(
|
child: Column(
|
||||||
children: [
|
children: [
|
||||||
@ -63,7 +64,8 @@ class _AddNewUserDialogState extends State<AddNewUserDialog> {
|
|||||||
children: [
|
children: [
|
||||||
_buildStep1Indicator(1, "Basics", _blocRole),
|
_buildStep1Indicator(1, "Basics", _blocRole),
|
||||||
_buildStep2Indicator(2, "Spaces", _blocRole),
|
_buildStep2Indicator(2, "Spaces", _blocRole),
|
||||||
_buildStep3Indicator(3, "Role & Permissions", _blocRole),
|
_buildStep3Indicator(
|
||||||
|
3, "Role & Permissions", _blocRole),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
@ -105,18 +107,32 @@ class _AddNewUserDialogState extends State<AddNewUserDialog> {
|
|||||||
),
|
),
|
||||||
InkWell(
|
InkWell(
|
||||||
onTap: () {
|
onTap: () {
|
||||||
|
final isBasicsStep = currentStep == 1;
|
||||||
|
|
||||||
|
if (isBasicsStep) {
|
||||||
|
// Validate the form first
|
||||||
|
final isValid = _blocRole.formKey.currentState
|
||||||
|
?.validate() ??
|
||||||
|
false;
|
||||||
|
|
||||||
|
if (!isValid)
|
||||||
|
return; // Stop if form is not valid
|
||||||
|
}
|
||||||
_blocRole.add(const CheckEmailEvent());
|
_blocRole.add(const CheckEmailEvent());
|
||||||
|
|
||||||
setState(() {
|
setState(() {
|
||||||
if (currentStep < 3) {
|
if (currentStep < 3) {
|
||||||
currentStep++;
|
currentStep++;
|
||||||
if (currentStep == 2) {
|
if (currentStep == 2) {
|
||||||
_blocRole.add(const CheckStepStatus(isEditUser: false));
|
_blocRole.add(const CheckStepStatus(
|
||||||
|
isEditUser: false));
|
||||||
} else if (currentStep == 3) {
|
} else if (currentStep == 3) {
|
||||||
_blocRole.add(const CheckSpacesStepStatus());
|
_blocRole
|
||||||
|
.add(const CheckSpacesStepStatus());
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
_blocRole.add(SendInviteUsers(context: context));
|
_blocRole
|
||||||
|
.add(SendInviteUsers(context: context));
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
@ -124,8 +140,11 @@ class _AddNewUserDialogState extends State<AddNewUserDialog> {
|
|||||||
currentStep < 3 ? "Next" : "Save",
|
currentStep < 3 ? "Next" : "Save",
|
||||||
style: TextStyle(
|
style: TextStyle(
|
||||||
color: (_blocRole.isCompleteSpaces == false ||
|
color: (_blocRole.isCompleteSpaces == false ||
|
||||||
_blocRole.isCompleteBasics == false ||
|
_blocRole.isCompleteBasics ==
|
||||||
_blocRole.isCompleteRolePermissions == false) &&
|
false ||
|
||||||
|
_blocRole
|
||||||
|
.isCompleteRolePermissions ==
|
||||||
|
false) &&
|
||||||
currentStep == 3
|
currentStep == 3
|
||||||
? ColorsManager.grayColor
|
? ColorsManager.grayColor
|
||||||
: ColorsManager.secondaryColor),
|
: ColorsManager.secondaryColor),
|
||||||
@ -143,7 +162,7 @@ class _AddNewUserDialogState extends State<AddNewUserDialog> {
|
|||||||
Widget _getFormContent() {
|
Widget _getFormContent() {
|
||||||
switch (currentStep) {
|
switch (currentStep) {
|
||||||
case 1:
|
case 1:
|
||||||
return const BasicsView(
|
return BasicsView(
|
||||||
userId: '',
|
userId: '',
|
||||||
);
|
);
|
||||||
case 2:
|
case 2:
|
||||||
@ -196,8 +215,12 @@ class _AddNewUserDialogState extends State<AddNewUserDialog> {
|
|||||||
label,
|
label,
|
||||||
style: TextStyle(
|
style: TextStyle(
|
||||||
fontSize: 16,
|
fontSize: 16,
|
||||||
color: currentStep == step ? ColorsManager.blackColor : ColorsManager.greyColor,
|
color: currentStep == step
|
||||||
fontWeight: currentStep == step ? FontWeight.bold : FontWeight.normal,
|
? ColorsManager.blackColor
|
||||||
|
: ColorsManager.greyColor,
|
||||||
|
fontWeight: currentStep == step
|
||||||
|
? FontWeight.bold
|
||||||
|
: FontWeight.normal,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
@ -260,8 +283,12 @@ class _AddNewUserDialogState extends State<AddNewUserDialog> {
|
|||||||
label,
|
label,
|
||||||
style: TextStyle(
|
style: TextStyle(
|
||||||
fontSize: 16,
|
fontSize: 16,
|
||||||
color: currentStep == step ? ColorsManager.blackColor : ColorsManager.greyColor,
|
color: currentStep == step
|
||||||
fontWeight: currentStep == step ? FontWeight.bold : FontWeight.normal,
|
? ColorsManager.blackColor
|
||||||
|
: ColorsManager.greyColor,
|
||||||
|
fontWeight: currentStep == step
|
||||||
|
? FontWeight.bold
|
||||||
|
: FontWeight.normal,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
@ -318,8 +345,12 @@ class _AddNewUserDialogState extends State<AddNewUserDialog> {
|
|||||||
label,
|
label,
|
||||||
style: TextStyle(
|
style: TextStyle(
|
||||||
fontSize: 16,
|
fontSize: 16,
|
||||||
color: currentStep == step ? ColorsManager.blackColor : ColorsManager.greyColor,
|
color: currentStep == step
|
||||||
fontWeight: currentStep == step ? FontWeight.bold : FontWeight.normal,
|
? ColorsManager.blackColor
|
||||||
|
: ColorsManager.greyColor,
|
||||||
|
fontWeight: currentStep == step
|
||||||
|
? FontWeight.bold
|
||||||
|
: FontWeight.normal,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
|
@ -1,9 +1,12 @@
|
|||||||
|
import 'dart:async';
|
||||||
|
|
||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
import 'package:flutter_bloc/flutter_bloc.dart';
|
import 'package:flutter_bloc/flutter_bloc.dart';
|
||||||
import 'package:intl_phone_field/countries.dart';
|
import 'package:intl_phone_field/countries.dart';
|
||||||
import 'package:intl_phone_field/country_picker_dialog.dart';
|
import 'package:intl_phone_field/country_picker_dialog.dart';
|
||||||
import 'package:intl_phone_field/intl_phone_field.dart';
|
import 'package:intl_phone_field/intl_phone_field.dart';
|
||||||
import 'package:syncrow_web/pages/roles_and_permission/users_page/add_user_dialog/bloc/users_bloc.dart';
|
import 'package:syncrow_web/pages/roles_and_permission/users_page/add_user_dialog/bloc/users_bloc.dart';
|
||||||
|
import 'package:syncrow_web/pages/roles_and_permission/users_page/add_user_dialog/bloc/users_event.dart';
|
||||||
import 'package:syncrow_web/pages/roles_and_permission/users_page/add_user_dialog/bloc/users_status.dart';
|
import 'package:syncrow_web/pages/roles_and_permission/users_page/add_user_dialog/bloc/users_status.dart';
|
||||||
import 'package:syncrow_web/utils/color_manager.dart';
|
import 'package:syncrow_web/utils/color_manager.dart';
|
||||||
import 'package:syncrow_web/utils/extension/build_context_x.dart';
|
import 'package:syncrow_web/utils/extension/build_context_x.dart';
|
||||||
@ -11,7 +14,9 @@ import 'package:syncrow_web/utils/style.dart';
|
|||||||
|
|
||||||
class BasicsView extends StatelessWidget {
|
class BasicsView extends StatelessWidget {
|
||||||
final String? userId;
|
final String? userId;
|
||||||
const BasicsView({super.key, this.userId = ''});
|
Timer? _debounce;
|
||||||
|
|
||||||
|
BasicsView({super.key, this.userId = ''});
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
return BlocBuilder<UsersBloc, UsersState>(builder: (context, state) {
|
return BlocBuilder<UsersBloc, UsersState>(builder: (context, state) {
|
||||||
@ -21,6 +26,7 @@ class BasicsView extends StatelessWidget {
|
|||||||
}
|
}
|
||||||
return Form(
|
return Form(
|
||||||
key: _blocRole.formKey,
|
key: _blocRole.formKey,
|
||||||
|
autovalidateMode: AutovalidateMode.onUserInteraction,
|
||||||
child: ListView(
|
child: ListView(
|
||||||
shrinkWrap: true,
|
shrinkWrap: true,
|
||||||
children: [
|
children: [
|
||||||
@ -208,6 +214,14 @@ class BasicsView extends StatelessWidget {
|
|||||||
fontSize: 12,
|
fontSize: 12,
|
||||||
color: ColorsManager.textGray),
|
color: ColorsManager.textGray),
|
||||||
),
|
),
|
||||||
|
|
||||||
|
onChanged: (value) {
|
||||||
|
if (_debounce?.isActive ?? false) _debounce!.cancel();
|
||||||
|
_debounce = Timer(const Duration(milliseconds: 800), () {
|
||||||
|
_blocRole.add(const CheckEmailEvent());
|
||||||
|
});
|
||||||
|
},
|
||||||
|
|
||||||
validator: (value) {
|
validator: (value) {
|
||||||
if (value == null || value.isEmpty) {
|
if (value == null || value.isEmpty) {
|
||||||
return 'Enter Email Address';
|
return 'Enter Email Address';
|
||||||
|
@ -58,11 +58,14 @@ class ProductModel {
|
|||||||
'3G': Assets.Gang3SwitchIcon,
|
'3G': Assets.Gang3SwitchIcon,
|
||||||
'3GT': Assets.threeTouchSwitch,
|
'3GT': Assets.threeTouchSwitch,
|
||||||
'CUR': Assets.curtain,
|
'CUR': Assets.curtain,
|
||||||
|
'CUR_2': Assets.curtain,
|
||||||
'GD': Assets.garageDoor,
|
'GD': Assets.garageDoor,
|
||||||
'GW': Assets.SmartGatewayIcon,
|
'GW': Assets.SmartGatewayIcon,
|
||||||
'DL': Assets.DoorLockIcon,
|
'DL': Assets.DoorLockIcon,
|
||||||
'WL': Assets.waterLeakSensor,
|
'WL': Assets.waterLeakSensor,
|
||||||
'WH': Assets.waterHeater,
|
'WH': Assets.waterHeater,
|
||||||
|
'WM': Assets.waterLeakSensor,
|
||||||
|
'SOS': Assets.sos,
|
||||||
'AC': Assets.ac,
|
'AC': Assets.ac,
|
||||||
'CPS': Assets.presenceSensor,
|
'CPS': Assets.presenceSensor,
|
||||||
'PC': Assets.powerClamp,
|
'PC': Assets.powerClamp,
|
||||||
|
711
package-lock.json
generated
711
package-lock.json
generated
@ -1,711 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "syncrow-web-infrastructure",
|
|
||||||
"version": "1.0.0",
|
|
||||||
"lockfileVersion": 3,
|
|
||||||
"requires": true,
|
|
||||||
"packages": {
|
|
||||||
"": {
|
|
||||||
"name": "syncrow-web-infrastructure",
|
|
||||||
"version": "1.0.0",
|
|
||||||
"license": "ISC",
|
|
||||||
"dependencies": {
|
|
||||||
"source-map-support": "^0.5.21"
|
|
||||||
},
|
|
||||||
"devDependencies": {
|
|
||||||
"@types/node": "^24.0.12",
|
|
||||||
"aws-cdk-lib": "^2.204.0",
|
|
||||||
"constructs": "^10.4.2",
|
|
||||||
"ts-node": "^10.9.2",
|
|
||||||
"typescript": "^5.8.3"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/@aws-cdk/asset-awscli-v1": {
|
|
||||||
"version": "2.2.242",
|
|
||||||
"resolved": "https://registry.npmjs.org/@aws-cdk/asset-awscli-v1/-/asset-awscli-v1-2.2.242.tgz",
|
|
||||||
"integrity": "sha512-4c1bAy2ISzcdKXYS1k4HYZsNrgiwbiDzj36ybwFVxEWZXVAP0dimQTCaB9fxu7sWzEjw3d+eaw6Fon+QTfTIpQ==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "Apache-2.0"
|
|
||||||
},
|
|
||||||
"node_modules/@aws-cdk/asset-node-proxy-agent-v6": {
|
|
||||||
"version": "2.1.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/@aws-cdk/asset-node-proxy-agent-v6/-/asset-node-proxy-agent-v6-2.1.0.tgz",
|
|
||||||
"integrity": "sha512-7bY3J8GCVxLupn/kNmpPc5VJz8grx+4RKfnnJiO1LG+uxkZfANZG3RMHhE+qQxxwkyQ9/MfPtTpf748UhR425A==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "Apache-2.0"
|
|
||||||
},
|
|
||||||
"node_modules/@aws-cdk/cloud-assembly-schema": {
|
|
||||||
"version": "45.2.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/@aws-cdk/cloud-assembly-schema/-/cloud-assembly-schema-45.2.0.tgz",
|
|
||||||
"integrity": "sha512-5TTUkGHQ+nfuUGwKA8/Yraxb+JdNUh4np24qk/VHXmrCMq+M6HfmGWfhcg/QlHA2S5P3YIamfYHdQAB4uSNLAg==",
|
|
||||||
"bundleDependencies": [
|
|
||||||
"jsonschema",
|
|
||||||
"semver"
|
|
||||||
],
|
|
||||||
"dev": true,
|
|
||||||
"license": "Apache-2.0",
|
|
||||||
"dependencies": {
|
|
||||||
"jsonschema": "~1.4.1",
|
|
||||||
"semver": "^7.7.2"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">= 18.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/@aws-cdk/cloud-assembly-schema/node_modules/jsonschema": {
|
|
||||||
"version": "1.4.1",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"engines": {
|
|
||||||
"node": "*"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/@aws-cdk/cloud-assembly-schema/node_modules/semver": {
|
|
||||||
"version": "7.7.2",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "ISC",
|
|
||||||
"bin": {
|
|
||||||
"semver": "bin/semver.js"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=10"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/@cspotcode/source-map-support": {
|
|
||||||
"version": "0.8.1",
|
|
||||||
"resolved": "https://registry.npmjs.org/@cspotcode/source-map-support/-/source-map-support-0.8.1.tgz",
|
|
||||||
"integrity": "sha512-IchNf6dN4tHoMFIn/7OE8LWZ19Y6q/67Bmf6vnGREv8RSbBVb9LPJxEcnwrcwX6ixSvaiGoomAUvu4YSxXrVgw==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"@jridgewell/trace-mapping": "0.3.9"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=12"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/@jridgewell/resolve-uri": {
|
|
||||||
"version": "3.1.2",
|
|
||||||
"resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.2.tgz",
|
|
||||||
"integrity": "sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"engines": {
|
|
||||||
"node": ">=6.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/@jridgewell/sourcemap-codec": {
|
|
||||||
"version": "1.5.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.5.0.tgz",
|
|
||||||
"integrity": "sha512-gv3ZRaISU3fjPAgNsriBRqGWQL6quFx04YMPW/zD8XMLsU32mhCCbfbO6KZFLjvYpCZ8zyDEgqsgf+PwPaM7GQ==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT"
|
|
||||||
},
|
|
||||||
"node_modules/@jridgewell/trace-mapping": {
|
|
||||||
"version": "0.3.9",
|
|
||||||
"resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.9.tgz",
|
|
||||||
"integrity": "sha512-3Belt6tdc8bPgAtbcmdtNJlirVoTmEb5e2gC94PnkwEW9jI6CAHUeoG85tjWP5WquqfavoMtMwiG4P926ZKKuQ==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"@jridgewell/resolve-uri": "^3.0.3",
|
|
||||||
"@jridgewell/sourcemap-codec": "^1.4.10"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/@tsconfig/node10": {
|
|
||||||
"version": "1.0.11",
|
|
||||||
"resolved": "https://registry.npmjs.org/@tsconfig/node10/-/node10-1.0.11.tgz",
|
|
||||||
"integrity": "sha512-DcRjDCujK/kCk/cUe8Xz8ZSpm8mS3mNNpta+jGCA6USEDfktlNvm1+IuZ9eTcDbNk41BHwpHHeW+N1lKCz4zOw==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT"
|
|
||||||
},
|
|
||||||
"node_modules/@tsconfig/node12": {
|
|
||||||
"version": "1.0.11",
|
|
||||||
"resolved": "https://registry.npmjs.org/@tsconfig/node12/-/node12-1.0.11.tgz",
|
|
||||||
"integrity": "sha512-cqefuRsh12pWyGsIoBKJA9luFu3mRxCA+ORZvA4ktLSzIuCUtWVxGIuXigEwO5/ywWFMZ2QEGKWvkZG1zDMTag==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT"
|
|
||||||
},
|
|
||||||
"node_modules/@tsconfig/node14": {
|
|
||||||
"version": "1.0.3",
|
|
||||||
"resolved": "https://registry.npmjs.org/@tsconfig/node14/-/node14-1.0.3.tgz",
|
|
||||||
"integrity": "sha512-ysT8mhdixWK6Hw3i1V2AeRqZ5WfXg1G43mqoYlM2nc6388Fq5jcXyr5mRsqViLx/GJYdoL0bfXD8nmF+Zn/Iow==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT"
|
|
||||||
},
|
|
||||||
"node_modules/@tsconfig/node16": {
|
|
||||||
"version": "1.0.4",
|
|
||||||
"resolved": "https://registry.npmjs.org/@tsconfig/node16/-/node16-1.0.4.tgz",
|
|
||||||
"integrity": "sha512-vxhUy4J8lyeyinH7Azl1pdd43GJhZH/tP2weN8TntQblOY+A0XbT8DJk1/oCPuOOyg/Ja757rG0CgHcWC8OfMA==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT"
|
|
||||||
},
|
|
||||||
"node_modules/@types/node": {
|
|
||||||
"version": "24.0.12",
|
|
||||||
"resolved": "https://registry.npmjs.org/@types/node/-/node-24.0.12.tgz",
|
|
||||||
"integrity": "sha512-LtOrbvDf5ndC9Xi+4QZjVL0woFymF/xSTKZKPgrrl7H7XoeDvnD+E2IclKVDyaK9UM756W/3BXqSU+JEHopA9g==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"undici-types": "~7.8.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/acorn": {
|
|
||||||
"version": "8.15.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/acorn/-/acorn-8.15.0.tgz",
|
|
||||||
"integrity": "sha512-NZyJarBfL7nWwIq+FDL6Zp/yHEhePMNnnJ0y3qfieCrmNvYct8uvtiV41UvlSe6apAfk0fY1FbWx+NwfmpvtTg==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"bin": {
|
|
||||||
"acorn": "bin/acorn"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=0.4.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/acorn-walk": {
|
|
||||||
"version": "8.3.4",
|
|
||||||
"resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-8.3.4.tgz",
|
|
||||||
"integrity": "sha512-ueEepnujpqee2o5aIYnvHU6C0A42MNdsIDeqy5BydrkuC5R1ZuUFnm27EeFJGoEHJQgn3uleRvmTXaJgfXbt4g==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"acorn": "^8.11.0"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=0.4.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/arg": {
|
|
||||||
"version": "4.1.3",
|
|
||||||
"resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz",
|
|
||||||
"integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT"
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib": {
|
|
||||||
"version": "2.204.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/aws-cdk-lib/-/aws-cdk-lib-2.204.0.tgz",
|
|
||||||
"integrity": "sha512-mY3nYu+QvPhO+fz+LCFKbc0PFhTHbHzDLnbcA2fPcQBKciYnTixpBd2ccRlKYWbG4y6NTc6ju6DudZ3HIS4OlA==",
|
|
||||||
"bundleDependencies": [
|
|
||||||
"@balena/dockerignore",
|
|
||||||
"case",
|
|
||||||
"fs-extra",
|
|
||||||
"ignore",
|
|
||||||
"jsonschema",
|
|
||||||
"minimatch",
|
|
||||||
"punycode",
|
|
||||||
"semver",
|
|
||||||
"table",
|
|
||||||
"yaml",
|
|
||||||
"mime-types"
|
|
||||||
],
|
|
||||||
"dev": true,
|
|
||||||
"license": "Apache-2.0",
|
|
||||||
"dependencies": {
|
|
||||||
"@aws-cdk/asset-awscli-v1": "2.2.242",
|
|
||||||
"@aws-cdk/asset-node-proxy-agent-v6": "^2.1.0",
|
|
||||||
"@aws-cdk/cloud-assembly-schema": "^45.0.0",
|
|
||||||
"@balena/dockerignore": "^1.0.2",
|
|
||||||
"case": "1.6.3",
|
|
||||||
"fs-extra": "^11.3.0",
|
|
||||||
"ignore": "^5.3.2",
|
|
||||||
"jsonschema": "^1.5.0",
|
|
||||||
"mime-types": "^2.1.35",
|
|
||||||
"minimatch": "^3.1.2",
|
|
||||||
"punycode": "^2.3.1",
|
|
||||||
"semver": "^7.7.2",
|
|
||||||
"table": "^6.9.0",
|
|
||||||
"yaml": "1.10.2"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">= 14.15.0"
|
|
||||||
},
|
|
||||||
"peerDependencies": {
|
|
||||||
"constructs": "^10.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/@balena/dockerignore": {
|
|
||||||
"version": "1.0.2",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "Apache-2.0"
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/ajv": {
|
|
||||||
"version": "8.17.1",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"fast-deep-equal": "^3.1.3",
|
|
||||||
"fast-uri": "^3.0.1",
|
|
||||||
"json-schema-traverse": "^1.0.0",
|
|
||||||
"require-from-string": "^2.0.2"
|
|
||||||
},
|
|
||||||
"funding": {
|
|
||||||
"type": "github",
|
|
||||||
"url": "https://github.com/sponsors/epoberezkin"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/ansi-regex": {
|
|
||||||
"version": "5.0.1",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"engines": {
|
|
||||||
"node": ">=8"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/ansi-styles": {
|
|
||||||
"version": "4.3.0",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"color-convert": "^2.0.1"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=8"
|
|
||||||
},
|
|
||||||
"funding": {
|
|
||||||
"url": "https://github.com/chalk/ansi-styles?sponsor=1"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/astral-regex": {
|
|
||||||
"version": "2.0.0",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"engines": {
|
|
||||||
"node": ">=8"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/balanced-match": {
|
|
||||||
"version": "1.0.2",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "MIT"
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/brace-expansion": {
|
|
||||||
"version": "1.1.12",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"balanced-match": "^1.0.0",
|
|
||||||
"concat-map": "0.0.1"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/case": {
|
|
||||||
"version": "1.6.3",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "(MIT OR GPL-3.0-or-later)",
|
|
||||||
"engines": {
|
|
||||||
"node": ">= 0.8.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/color-convert": {
|
|
||||||
"version": "2.0.1",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"color-name": "~1.1.4"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=7.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/color-name": {
|
|
||||||
"version": "1.1.4",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "MIT"
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/concat-map": {
|
|
||||||
"version": "0.0.1",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "MIT"
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/emoji-regex": {
|
|
||||||
"version": "8.0.0",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "MIT"
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/fast-deep-equal": {
|
|
||||||
"version": "3.1.3",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "MIT"
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/fast-uri": {
|
|
||||||
"version": "3.0.6",
|
|
||||||
"dev": true,
|
|
||||||
"funding": [
|
|
||||||
{
|
|
||||||
"type": "github",
|
|
||||||
"url": "https://github.com/sponsors/fastify"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "opencollective",
|
|
||||||
"url": "https://opencollective.com/fastify"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "BSD-3-Clause"
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/fs-extra": {
|
|
||||||
"version": "11.3.0",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"graceful-fs": "^4.2.0",
|
|
||||||
"jsonfile": "^6.0.1",
|
|
||||||
"universalify": "^2.0.0"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=14.14"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/graceful-fs": {
|
|
||||||
"version": "4.2.11",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "ISC"
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/ignore": {
|
|
||||||
"version": "5.3.2",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"engines": {
|
|
||||||
"node": ">= 4"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/is-fullwidth-code-point": {
|
|
||||||
"version": "3.0.0",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"engines": {
|
|
||||||
"node": ">=8"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/json-schema-traverse": {
|
|
||||||
"version": "1.0.0",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "MIT"
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/jsonfile": {
|
|
||||||
"version": "6.1.0",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"universalify": "^2.0.0"
|
|
||||||
},
|
|
||||||
"optionalDependencies": {
|
|
||||||
"graceful-fs": "^4.1.6"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/jsonschema": {
|
|
||||||
"version": "1.5.0",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"engines": {
|
|
||||||
"node": "*"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/lodash.truncate": {
|
|
||||||
"version": "4.4.2",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "MIT"
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/mime-db": {
|
|
||||||
"version": "1.52.0",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"engines": {
|
|
||||||
"node": ">= 0.6"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/mime-types": {
|
|
||||||
"version": "2.1.35",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"mime-db": "1.52.0"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">= 0.6"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/minimatch": {
|
|
||||||
"version": "3.1.2",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "ISC",
|
|
||||||
"dependencies": {
|
|
||||||
"brace-expansion": "^1.1.7"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": "*"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/punycode": {
|
|
||||||
"version": "2.3.1",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"engines": {
|
|
||||||
"node": ">=6"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/require-from-string": {
|
|
||||||
"version": "2.0.2",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"engines": {
|
|
||||||
"node": ">=0.10.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/semver": {
|
|
||||||
"version": "7.7.2",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "ISC",
|
|
||||||
"bin": {
|
|
||||||
"semver": "bin/semver.js"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=10"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/slice-ansi": {
|
|
||||||
"version": "4.0.0",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"ansi-styles": "^4.0.0",
|
|
||||||
"astral-regex": "^2.0.0",
|
|
||||||
"is-fullwidth-code-point": "^3.0.0"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=10"
|
|
||||||
},
|
|
||||||
"funding": {
|
|
||||||
"url": "https://github.com/chalk/slice-ansi?sponsor=1"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/string-width": {
|
|
||||||
"version": "4.2.3",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"emoji-regex": "^8.0.0",
|
|
||||||
"is-fullwidth-code-point": "^3.0.0",
|
|
||||||
"strip-ansi": "^6.0.1"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=8"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/strip-ansi": {
|
|
||||||
"version": "6.0.1",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"ansi-regex": "^5.0.1"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=8"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/table": {
|
|
||||||
"version": "6.9.0",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "BSD-3-Clause",
|
|
||||||
"dependencies": {
|
|
||||||
"ajv": "^8.0.1",
|
|
||||||
"lodash.truncate": "^4.4.2",
|
|
||||||
"slice-ansi": "^4.0.0",
|
|
||||||
"string-width": "^4.2.3",
|
|
||||||
"strip-ansi": "^6.0.1"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=10.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/universalify": {
|
|
||||||
"version": "2.0.1",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"engines": {
|
|
||||||
"node": ">= 10.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/aws-cdk-lib/node_modules/yaml": {
|
|
||||||
"version": "1.10.2",
|
|
||||||
"dev": true,
|
|
||||||
"inBundle": true,
|
|
||||||
"license": "ISC",
|
|
||||||
"engines": {
|
|
||||||
"node": ">= 6"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/buffer-from": {
|
|
||||||
"version": "1.1.2",
|
|
||||||
"resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz",
|
|
||||||
"integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==",
|
|
||||||
"license": "MIT"
|
|
||||||
},
|
|
||||||
"node_modules/constructs": {
|
|
||||||
"version": "10.4.2",
|
|
||||||
"resolved": "https://registry.npmjs.org/constructs/-/constructs-10.4.2.tgz",
|
|
||||||
"integrity": "sha512-wsNxBlAott2qg8Zv87q3eYZYgheb9lchtBfjHzzLHtXbttwSrHPs1NNQbBrmbb1YZvYg2+Vh0Dor76w4mFxJkA==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "Apache-2.0"
|
|
||||||
},
|
|
||||||
"node_modules/create-require": {
|
|
||||||
"version": "1.1.1",
|
|
||||||
"resolved": "https://registry.npmjs.org/create-require/-/create-require-1.1.1.tgz",
|
|
||||||
"integrity": "sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT"
|
|
||||||
},
|
|
||||||
"node_modules/diff": {
|
|
||||||
"version": "4.0.2",
|
|
||||||
"resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz",
|
|
||||||
"integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "BSD-3-Clause",
|
|
||||||
"engines": {
|
|
||||||
"node": ">=0.3.1"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/make-error": {
|
|
||||||
"version": "1.3.6",
|
|
||||||
"resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz",
|
|
||||||
"integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "ISC"
|
|
||||||
},
|
|
||||||
"node_modules/source-map": {
|
|
||||||
"version": "0.6.1",
|
|
||||||
"resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz",
|
|
||||||
"integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==",
|
|
||||||
"license": "BSD-3-Clause",
|
|
||||||
"engines": {
|
|
||||||
"node": ">=0.10.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/source-map-support": {
|
|
||||||
"version": "0.5.21",
|
|
||||||
"resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.21.tgz",
|
|
||||||
"integrity": "sha512-uBHU3L3czsIyYXKX88fdrGovxdSCoTGDRZ6SYXtSRxLZUzHg5P/66Ht6uoUlHu9EZod+inXhKo3qQgwXUT/y1w==",
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"buffer-from": "^1.0.0",
|
|
||||||
"source-map": "^0.6.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/ts-node": {
|
|
||||||
"version": "10.9.2",
|
|
||||||
"resolved": "https://registry.npmjs.org/ts-node/-/ts-node-10.9.2.tgz",
|
|
||||||
"integrity": "sha512-f0FFpIdcHgn8zcPSbf1dRevwt047YMnaiJM3u2w2RewrB+fob/zePZcrOyQoLMMO7aBIddLcQIEK5dYjkLnGrQ==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"@cspotcode/source-map-support": "^0.8.0",
|
|
||||||
"@tsconfig/node10": "^1.0.7",
|
|
||||||
"@tsconfig/node12": "^1.0.7",
|
|
||||||
"@tsconfig/node14": "^1.0.0",
|
|
||||||
"@tsconfig/node16": "^1.0.2",
|
|
||||||
"acorn": "^8.4.1",
|
|
||||||
"acorn-walk": "^8.1.1",
|
|
||||||
"arg": "^4.1.0",
|
|
||||||
"create-require": "^1.1.0",
|
|
||||||
"diff": "^4.0.1",
|
|
||||||
"make-error": "^1.1.1",
|
|
||||||
"v8-compile-cache-lib": "^3.0.1",
|
|
||||||
"yn": "3.1.1"
|
|
||||||
},
|
|
||||||
"bin": {
|
|
||||||
"ts-node": "dist/bin.js",
|
|
||||||
"ts-node-cwd": "dist/bin-cwd.js",
|
|
||||||
"ts-node-esm": "dist/bin-esm.js",
|
|
||||||
"ts-node-script": "dist/bin-script.js",
|
|
||||||
"ts-node-transpile-only": "dist/bin-transpile.js",
|
|
||||||
"ts-script": "dist/bin-script-deprecated.js"
|
|
||||||
},
|
|
||||||
"peerDependencies": {
|
|
||||||
"@swc/core": ">=1.2.50",
|
|
||||||
"@swc/wasm": ">=1.2.50",
|
|
||||||
"@types/node": "*",
|
|
||||||
"typescript": ">=2.7"
|
|
||||||
},
|
|
||||||
"peerDependenciesMeta": {
|
|
||||||
"@swc/core": {
|
|
||||||
"optional": true
|
|
||||||
},
|
|
||||||
"@swc/wasm": {
|
|
||||||
"optional": true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/typescript": {
|
|
||||||
"version": "5.8.3",
|
|
||||||
"resolved": "https://registry.npmjs.org/typescript/-/typescript-5.8.3.tgz",
|
|
||||||
"integrity": "sha512-p1diW6TqL9L07nNxvRMM7hMMw4c5XOo/1ibL4aAIGmSAt9slTE1Xgw5KWuof2uTOvCg9BY7ZRi+GaF+7sfgPeQ==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "Apache-2.0",
|
|
||||||
"bin": {
|
|
||||||
"tsc": "bin/tsc",
|
|
||||||
"tsserver": "bin/tsserver"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=14.17"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/undici-types": {
|
|
||||||
"version": "7.8.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/undici-types/-/undici-types-7.8.0.tgz",
|
|
||||||
"integrity": "sha512-9UJ2xGDvQ43tYyVMpuHlsgApydB8ZKfVYTsLDhXkFL/6gfkp+U8xTGdh8pMJv1SpZna0zxG1DwsKZsreLbXBxw==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT"
|
|
||||||
},
|
|
||||||
"node_modules/v8-compile-cache-lib": {
|
|
||||||
"version": "3.0.1",
|
|
||||||
"resolved": "https://registry.npmjs.org/v8-compile-cache-lib/-/v8-compile-cache-lib-3.0.1.tgz",
|
|
||||||
"integrity": "sha512-wa7YjyUGfNZngI/vtK0UHAN+lgDCxBPCylVXGp0zu59Fz5aiGtNXaq3DhIov063MorB+VfufLh3JlF2KdTK3xg==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT"
|
|
||||||
},
|
|
||||||
"node_modules/yn": {
|
|
||||||
"version": "3.1.1",
|
|
||||||
"resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz",
|
|
||||||
"integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"engines": {
|
|
||||||
"node": ">=6"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
29
package.json
29
package.json
@ -1,29 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "syncrow-web-infrastructure",
|
|
||||||
"version": "1.0.0",
|
|
||||||
"main": "index.js",
|
|
||||||
"scripts": {
|
|
||||||
"build": "tsc",
|
|
||||||
"watch": "tsc -w",
|
|
||||||
"test": "jest",
|
|
||||||
"build:flutter": "flutter pub get && flutter build web --release",
|
|
||||||
"cdk": "cdk",
|
|
||||||
"infra:deploy": "npm run build:flutter && cdk deploy SyncrowWebStack",
|
|
||||||
"infra:destroy": "cdk destroy SyncrowWebStack",
|
|
||||||
"infra:build": "bash build.sh"
|
|
||||||
},
|
|
||||||
"keywords": [],
|
|
||||||
"author": "",
|
|
||||||
"license": "ISC",
|
|
||||||
"description": "CDK infrastructure for Syncrow Web Application",
|
|
||||||
"dependencies": {
|
|
||||||
"source-map-support": "^0.5.21"
|
|
||||||
},
|
|
||||||
"devDependencies": {
|
|
||||||
"@types/node": "^24.0.12",
|
|
||||||
"aws-cdk-lib": "^2.204.0",
|
|
||||||
"constructs": "^10.4.2",
|
|
||||||
"ts-node": "^10.9.2",
|
|
||||||
"typescript": "^5.8.3"
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,35 +0,0 @@
|
|||||||
{
|
|
||||||
"compilerOptions": {
|
|
||||||
"target": "ES2020",
|
|
||||||
"module": "commonjs",
|
|
||||||
"lib": [
|
|
||||||
"es2020"
|
|
||||||
],
|
|
||||||
"declaration": true,
|
|
||||||
"strict": true,
|
|
||||||
"noImplicitAny": true,
|
|
||||||
"strictNullChecks": true,
|
|
||||||
"noImplicitThis": true,
|
|
||||||
"alwaysStrict": true,
|
|
||||||
"noUnusedLocals": false,
|
|
||||||
"noUnusedParameters": false,
|
|
||||||
"noImplicitReturns": true,
|
|
||||||
"noFallthroughCasesInSwitch": false,
|
|
||||||
"inlineSourceMap": true,
|
|
||||||
"inlineSources": true,
|
|
||||||
"experimentalDecorators": true,
|
|
||||||
"strictPropertyInitialization": false,
|
|
||||||
"typeRoots": [
|
|
||||||
"./node_modules/@types"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"exclude": [
|
|
||||||
"node_modules",
|
|
||||||
"cdk.out",
|
|
||||||
"build",
|
|
||||||
"lib",
|
|
||||||
"test",
|
|
||||||
"assets",
|
|
||||||
"web"
|
|
||||||
]
|
|
||||||
}
|
|
Reference in New Issue
Block a user