You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Feature Request: Add an [CC=email] similar to [TO=email] #545
Greetings.
Sorry for my bad english.
I suggest adding an [CC=email] field similar to [TO=email].
Template for insert in mail body looks like:
To: [[TO=email]]
CC: [[CC=email]]
Now I have to manually edit quicktextParser.mjs inside .xpi every time after addon's auto-update:
Add to const allowedTags:
... , 'CC', ...
After process_to and get_to blocks and before async parse(aStr) { block add:
(I add in a simpler format - without asking for full name - I only need to extract the addresses themselves, separated by commas):
async process_cc(aVariables) {
if (this.mData['CC'] && this.mData['CC'].checked)
return this.mData['CC'].data;
this.mData['CC'] = {};
this.mData['CC'].checked = true;
this.mData['CC'].data = { email: [] };
let details = await this.getDetails();
let emailAddresses = Array.isArray(details.cc) ? details.cc : (details.cc ? [details.cc] : []);
for (let i = 0; i < emailAddresses.length; i++) {
let contactData = await utils.parseDisplayName(emailAddresses[i]);
this.mData['CC'].data.email.push(contactData.email.toLowerCase());
}
return this.mData['CC'].data;
}
async get_cc(aVariables) {
let data = await this.process_cc(aVariables);
if (typeof data[aVariables[0]] != 'undefined') {
let mainSep = (aVariables.length > 1) ? aVariables[1].replace(/\n/g, "\n").replace(/\t/g, "\t") : ", ";
let lastSep = (aVariables.length > 2) ? aVariables[2].replace(/\n/g, "\n").replace(/\t/g, "\t") : mainSep;
let entries = data[aVariables[0]].slice(0);
let last = entries.pop();
let all = [];
if (entries.length > 0) all.push(entries.join(mainSep));
if (last) all.push(last);
return all.join(lastSep);
}
return "";
}
Add to switch (tags[i].tagName.toLowerCase()) { :
case 'cc':
Thanks for the great addon - it really helps in my work.
Activity
Froz0925 commentedon Aug 26, 2025
Updated blocks
process_ccandget_cc( use this.loadStates() instead of previous this.mData ) - tested on v6.4.6 and working:Enhanced full block
process_cc(similar to fullprocess_to) +getcarddata_cc- they are not tested yet, cause i don't need them in my use case: