# NOW


- UI to unbounce a user
- UI to restart mails 

- reset flow caches on update -> context menu as changed
- resourcelist: empty state / empty result on search/filter

BUG:
- changing gender in preview/editor does not affect/refresh other language tabs
- actions on template coupon


audience:
- copy
- export
- DONE: create new newsletter / automation
- show usage
- statistics (performance e.g. open/click rate, revenue)

Gender support filter_add_gender:
- WIP editor
- WIP preview


- WIP topic areas
- WIP coupon templates
- extensions (group, gender...)


- search / command menu

Bug:
- UI: configuration save overlay layout at bottom
- UI: show template usage -> many items break UI (not scrollable)
- new newsletter - end date is not prefilled (caused by sentinel timestamp?)
- legacy ui newsletter date prefilled with sentinel timestamp

Topbar
- review module loader to trigger module updates with cache refresh
- main templates - handle initial without saved template, empty state

newsletter:
- transfer collection archived status on mailbeez_newsletter_items, enhance smart lists to exclude archived items 
- hint selecting audience - source type must be the same (compare audicence dialog)
- copy newsletter (deep copy)
- newsletter - auto archive button in section archive - archive all selections with newsletters end date e.g. 6month ago
- limit e.g. "completed" smart filter by date (e.g. completed in last 3 months), same for "recently" - use common dateRange config

- check: configuration values stored in DB must be "True" or "False" - not on/off/1/0

- reorder_advanced
  - rules: minimum number of orders can be negative?
  - step flow card labels do not match


- WIP: module uninstall only on mailbeez modules - currently also on other modules

- trigger: re-enable custom flows tab and show automation flows
- translate modal titles in flows
- preview main template: add language switcher

- targetgroups
  - WIP topic
  - add option "automation" to audience for filtering when creating a new automation
  - templates for targetgroups (klaviyo, shopify)
  - export /list targetgroups
  - empty state button for targetgroups


- template coupons
  - finalize basic functionality
  - analytics for coupons
  - list all coupons for a template
  - generate static coupons based on a template
  - nice visual for view coupon template

- MailBeez
  - WIP: "+ add" button dialog
  - review and improve step edit labels (e.g."Edit Step1 Delay")
  - add automation -> "marketplace" layout, full screen, selection left
  - group by: touchpoint (e.g. order, account created) / marketing target (conversion, revenue, reviews, retention) 

- newsletter:
  - WIP: Smart Collections review / improve queries, add favorites
  - assign template coupon / UX to show if coupon is assigned and presentation in newsletter
  - Assign Coupon template to newsletter in Editor
  - finalize collection functionalities
    - sort order


  - tab for collections overview with analytics? cards on top of page?
  - "NEW" Button with dialog/assistant?
  - combined newsletter list : and/or combination of lists


- UI:
  - similar to Collections Dropdown visual for
    - list / audience
    - coupons
  - DONE: add coupon expire to step content
 
- WIP:  toggle hide inactives in itemList/trigger
- DONE: install/update/remove must trigger ModuleLoader refresh
- support preloading of pages in safari (app.php)

config_block_admin calls constructor of modules \mb_newsletter::_load_sourcebeez even in visual_editor.php


##LATER


- analytics
  - open rate over time, trend -> warning if delivery issues
  - revenue per list
  - list quality (openers, buyers...)
  - profiling of customers
  
- V5 editor
  - (postponed / cancelled: request target into iframe -> only 1 request)()
  - (postponed / cancelled: optimistic -> close modal on click )
  - module editor: 
    - optional open visual template selection for main template beside dropdown
  - newsletter editor:
    - DONE: select main template
    - save as template
    - import template
  - main template editor: 
    - review "email details" section. place button for style edit? 
    - WIP: usage of this template: open modal with a list of newsletters and automations using this template
      - options to retrieve assigned maintemplate_id for newsletters and automations
        - reverse from configuration: TABLE_MAILBEEZ_MODULE_CONFIGURATION -> cfg_value holds serialized array with (optional) maintemplate_id - /Users/Shared/MailBeez Repository/dev_mailbeez/catalog/mailhive/configbeez/config_editor/classes/template_manager.php
        - or iterate through all modules: template_manager::get_maintemplate_id($obj); like in catalog/mailhive/app_dev/pages/email_editor.php:404
    - add option to show skeleton or dummy content with different formats (H1,H2,... button, image)
  - mark language version as translated
  - export templates does not work (incompleted zip download)




- email preview
  - main template: option to show skeleton or dummy content with different formats (H1,H2,...

- editor templates:
  - main templates: make newsletter with this template
  - module templates: show supported languages
  - show usage - dialog improvements
  - intro text in main / module template pages
  - module template import: user templates as 2nd tab

- in edit dialog remember status of tools collapsible for all dialogs
- in columns dialog make text area larger


- DONE: unified pause/active button and badge

- DONE: dashboard: add placeholder skeleton
- DONE: trigger: translate sections labels
- DONE: itemList audience: add filter pills
- DONE: ungrouped -> listLayout not stored
- DONE: install module -> switch to grouped mode
- DONE: RadioGroup remove audience specific message
- DONE: remove CONF_SAVED_ on uninstall module

- DONE: toolbar
- DONE: drawer module: sticky save buttons header or footer
- DONE: auto save info (timeago, with event listener)
- DONE: adopt for mb_newsletter - timeframe configuration in header
- DONE: adopt for single language tmpl_mngr
- DONE: design conditionbadge outline
- DONE: BUG: status badge for automation is "ended" (must be active)
- DONE: BUG: activate confirm dialog: "The Newsletter will be sent out:" fix timeframe, translate
- DONE: BUG: trigger newsletter_item:updated after editing name/description of first mail item
- DONE: dateRange color must adopt dynamically
- DONE: name/description for mail item (pre-generated from subject/preheader, editable) - make dialog, accessible from flow and editor
- DONE: afterSend action
- DONE: cache flow with newsletter_item, refresh with any change in newsletter_item
- DONE: main templates: user can create a new template from a gallery template (klaviyo: Vorlage verwenden)
- DONE: main templates: user can set a template as default / standard template (overwrite? rename?)
- DONE: (more characters) add name text field? generate slug from name?
- DONE: add date to template cards
- DONE: trigger to refresh template list after edit/adding/deleting/importing/creating...
- DONE: after sent action: save & close button
- DONE: configStoreProvider: save into mailbeez_module_configuration table instead of gx_configurations
- DONE: Review LiveConfigProvider - stores currently into mailbeez_module_configuration
- DONE: Refactor ConfigStore and CacheProvider into a common base class
- DONE: BUG: module config  cfg_id	cfg_key	cfg_value	last_modified	date_added coupon_birthday:2025	a:1:{s:15:"maintemplate_id";s:4:"MAIN";}	2025-06-23 11:10:51	2025-06-23 11:10:51
- DONE: BUG: newsletter nerdmode, textmode on save handler missing
- DONE: configuration: save success message is smaller in height than the buttons -> keep height
- DONE: configuration: load/preload into divs for faster navigation
- DONE: toggle images on / off
- DONE: email preview: navigate to next email in module flows
- DONE: when importing a template, the refresh subject and preheader must be triggered for all languages
- DONE: Editor undo/redo functionalities
  /Users/cord/Library/Application Support/JetBrains/PhpStorm2025.2/scratches/analyse_the_functions_used_to_store_emai.md    
- DONE: indicator if template is default/standard
- DONE: ~~feature "set as default/standard"~~ Import into Main
- DONE: + - button rounded hover effect
- DONE: edit styling
- DONE: nerdmode, textmode 
- DONE: ItemList: Gear -> vertical ellipsis menu, configuration, status on /off ...
- DONE: ListLayout menu -> find different icon 
- DONE: Show Subject


- DONE: IMPORTANT: check DB issues probably caused by large newsletter_item_meta (JSON) columns?
- DONE: Model NewsletterItems
- DONE: SELECT * FROM mailbeez_newsletter_items WHERE newsletter_item_type = 0 ORDER BY newsletter_item_id DESC
- DONE: ALTER TABLE mailbeez_newsletter_items ADD INDEX idx_type_id (newsletter_item_type, newsletter_item_id);
- DONE: issue: invalid timestamps in last_modified
- DONE: ISSUE: preview e.g. winback advanced is empty!?!?!
- DONE: tabs smaller -> dropdown if too many tabs
- DONE: newsletter - handle empty state
- DONE: trigger modules - handle empty state
- DONE: doi flow horizontal scroll hints
- DONE: status badge shows invalid status e.g. completed for scheduled newsletter
- DONE: list/columns menu: highlight current view
- DONE: Audience - button, label, tab translation, empty state
- DONE: color
- DONE: archive toggle with collection section "archive" collapsible
- DONE: delete empty collections
- DONE: improve collection layout
- DONE: Add Update notifications
- DONE: Add changelog
- DONE: zencart 2: add security token to all post requests
- DONE: .md FAQ section collapsible
- DONE: template preview with customer_gender extension renders dialoge instead of template
- DONE: error on modified:  mailbeez.php?cloudloader_done=ok&nav=dashboard
- DONE: mailbeez analytics: open from ellipsis menu in trigger, step menue...
- DONE: clickable hover: > icon \Components\Base::SVG_CHEVRON_RIGHT
- DONE: action menu hover: (...) icon \Components\Base::SVG_ELLIPSIS_HORIZONTAL_CIRCLE_OUTLINE
- DONE: unnecessary menue divider e.g. in DOI flow action menu
- DONE: coupon dropdown: color dots by type \Components\Models\Coupon::getIcon
- DONE: topics: make tab "public", "private"
- DONE: exclude template coupons from list of generated coupons
