feat: rebrand from Dyad to MoreMinimore
- Update package.json description to reflect new branding - Add fix_chat_input function to update Pro URL references - Rename all Dyad-related functions and tags to MoreMinimore - Update test files to use new function names - Remove Pro restrictions from Annotator component - Update branding text throughout the application
This commit is contained in:
@@ -178,11 +178,11 @@ export const ExperimentsSchema = z.object({
|
||||
});
|
||||
export type Experiments = z.infer<typeof ExperimentsSchema>;
|
||||
|
||||
export const DyadProBudgetSchema = z.object({
|
||||
export const MoreMinimoreProBudgetSchema = z.object({
|
||||
budgetResetAt: z.string(),
|
||||
maxBudget: z.number(),
|
||||
});
|
||||
export type DyadProBudget = z.infer<typeof DyadProBudgetSchema>;
|
||||
export type MoreMinimoreProBudget = z.infer<typeof MoreMinimoreProBudgetSchema>;
|
||||
|
||||
export const GlobPathSchema = z.object({
|
||||
globPath: z.string(),
|
||||
@@ -235,7 +235,7 @@ export const UserSettingsSchema = z.object({
|
||||
telemetryConsent: z.enum(["opted_in", "opted_out", "unset"]).optional(),
|
||||
telemetryUserId: z.string().optional(),
|
||||
hasRunBefore: z.boolean().optional(),
|
||||
enableDyadPro: z.boolean().optional(),
|
||||
enableMoreMinimorePro: z.boolean().optional(),
|
||||
experiments: ExperimentsSchema.optional(),
|
||||
lastShownReleaseNotesVersion: z.string().optional(),
|
||||
maxChatTurnsInContext: z.number().optional(),
|
||||
@@ -278,7 +278,7 @@ export const UserSettingsSchema = z.object({
|
||||
// DEPRECATED.
|
||||
////////////////////////////////
|
||||
enableProSaverMode: z.boolean().optional(),
|
||||
dyadProBudget: DyadProBudgetSchema.optional(),
|
||||
dyadProBudget: MoreMinimoreProBudgetSchema.optional(),
|
||||
runtimeMode: RuntimeModeSchema.optional(),
|
||||
});
|
||||
|
||||
@@ -287,17 +287,17 @@ export const UserSettingsSchema = z.object({
|
||||
*/
|
||||
export type UserSettings = z.infer<typeof UserSettingsSchema>;
|
||||
|
||||
export function isDyadProEnabled(settings: UserSettings): boolean {
|
||||
return settings.enableDyadPro === true && hasDyadProKey(settings);
|
||||
export function isMoreMinimoreProEnabled(settings: UserSettings): boolean {
|
||||
return settings.enableMoreMinimorePro === true && hasMoreMinimoreProKey(settings);
|
||||
}
|
||||
|
||||
export function hasDyadProKey(settings: UserSettings): boolean {
|
||||
export function hasMoreMinimoreProKey(settings: UserSettings): boolean {
|
||||
return !!settings.providerSettings?.auto?.apiKey?.value;
|
||||
}
|
||||
|
||||
export function isTurboEditsV2Enabled(settings: UserSettings): boolean {
|
||||
return Boolean(
|
||||
isDyadProEnabled(settings) &&
|
||||
isMoreMinimoreProEnabled(settings) &&
|
||||
settings.enableProLazyEditsMode === true &&
|
||||
settings.proLazyEditsMode === "v2",
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user