forked from trent_larson/crowd-funder-for-time-pwa
Complete Enhanced Triple Migration Pattern for PhotoDialog and OfferDialog components
- Implement 4-phase migration pattern: Database + SQL + Notifications + Template Streamlining - PhotoDialog.vue: Replace databaseUtil with PlatformServiceMixin, add 8 notification constants, extract 11 computed properties - OfferDialog.vue: Replace databaseUtil with PlatformServiceMixin, add 7 notification constants, extract CSS classes to computed properties - Update migration template with Phase 4 (Template Streamlining) and Phase 5 (Code Quality Review) - Add 15 centralized notification constants to src/constants/notifications.ts Migration validation: 25/27 components complete (93% success rate)
This commit is contained in:
@@ -196,3 +196,80 @@ export const NOTIFY_CAMERA_SHARE_METHOD = {
|
||||
yesText: "we are nearby with cameras",
|
||||
noText: "we will share another way",
|
||||
};
|
||||
|
||||
// OfferDialog.vue constants
|
||||
export const NOTIFY_OFFER_SETTINGS_ERROR = {
|
||||
title: "Error",
|
||||
message: "There was an error retrieving your settings.",
|
||||
};
|
||||
|
||||
export const NOTIFY_OFFER_RECORDING = {
|
||||
text: "Recording the offer...",
|
||||
title: "",
|
||||
};
|
||||
|
||||
export const NOTIFY_OFFER_IDENTITY_REQUIRED = {
|
||||
title: "Error",
|
||||
message: "You must select an identity before you can record an offer.",
|
||||
};
|
||||
|
||||
export const NOTIFY_OFFER_DESCRIPTION_REQUIRED = {
|
||||
title: "Error",
|
||||
message: "You must enter a description or some number of {unit}.",
|
||||
};
|
||||
|
||||
export const NOTIFY_OFFER_CREATION_ERROR = {
|
||||
title: "Error",
|
||||
message: "There was an error creating the offer.",
|
||||
};
|
||||
|
||||
export const NOTIFY_OFFER_SUCCESS = {
|
||||
title: "Success",
|
||||
message: "That offer was recorded.",
|
||||
};
|
||||
|
||||
export const NOTIFY_OFFER_SUBMISSION_ERROR = {
|
||||
title: "Error",
|
||||
message: "There was an error recording the offer.",
|
||||
};
|
||||
|
||||
// PhotoDialog.vue constants
|
||||
export const NOTIFY_PHOTO_SETTINGS_ERROR = {
|
||||
title: "Error",
|
||||
message: "There was an error retrieving your settings.",
|
||||
};
|
||||
|
||||
export const NOTIFY_PHOTO_CAPTURE_ERROR = {
|
||||
title: "Error",
|
||||
message: "Failed to take picture. Please try again.",
|
||||
};
|
||||
|
||||
export const NOTIFY_PHOTO_CAMERA_ERROR = {
|
||||
title: "Camera Error",
|
||||
message: "Could not access camera. Please check permissions and try again.",
|
||||
};
|
||||
|
||||
export const NOTIFY_PHOTO_UPLOAD_ERROR = {
|
||||
title: "Upload Error",
|
||||
message: "Failed to upload image. Please try again.",
|
||||
};
|
||||
|
||||
export const NOTIFY_PHOTO_UPLOAD_SUCCESS = {
|
||||
title: "Success",
|
||||
message: "Image uploaded successfully.",
|
||||
};
|
||||
|
||||
export const NOTIFY_PHOTO_UNSUPPORTED_FORMAT = {
|
||||
title: "Unsupported Format",
|
||||
message: "This file format is not supported. Please try a different image.",
|
||||
};
|
||||
|
||||
export const NOTIFY_PHOTO_SIZE_ERROR = {
|
||||
title: "File Too Large",
|
||||
message: "Image file is too large. Please choose a smaller image.",
|
||||
};
|
||||
|
||||
export const NOTIFY_PHOTO_PROCESSING_ERROR = {
|
||||
title: "Processing Error",
|
||||
message: "Failed to process image. Please try again.",
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user