[New Plugin] Air Copy to clipboard

hi @rico will take a look at it.
thanks

Please let me know if you have a solution as I do prefer the workflow to the element.

Thank you :slight_smile:

hi, is it possible to copy all element that has the same id attr? the reason is i want to copy not just a repeating group but also a text element like if i want to copy a list of things but thereā€™s a total amount of all things if i include the total amount in the repeating group it will show a total amount in each things so i want to separate it using a text element see ex. below

RG list with id attr = items

item 1
item 2
item 3

Text element with id attr = items

Total Items 3

clip

so that the result all items from 1 to 3 including Total items will be copied
item 1
item 2
item 3

Total Items 3

hope you got my point :slight_smile:

i got it work i just add them all in a group element then i added an ID attr in that group the result is it will copy all text that was inside a group element

Great, that can can be very useful, thank you for posting, can you please explain how you addressed the group by ID attribute? Did you just put the group name into the ID attribute field? I am not yet understanding how this works.

Update: the workflow only worked on my phone but not on the phone of my partner. Iā€™ll now style the elements to represent buttons. Iā€™ll add text and icons on top and hope they will let the click through. A transparent aircopy element on top of buttons did not work.

Do you have a timeline to allow text and worflows in the element?

Update 2 Text overlay on the button does not work as well. So the only option I see now is a blank button? @seanhoots, please help if you can as copy to clipboard is core functionality of my App.

Thank you.

1 Like

just put all element inside a group element then add an id attr to that group itā€™s up to you what id attr you will put then just add that id to air copy target element id attr

I can not see where to add the id attr. in the group. could you send me a screenshot pls?

Hi @rico,
You assign id attribute for a group same way as you do for a button or text (or any other element.
Once youā€™ve enabled the option to specify the id attribute of elements in the Settings page, General tab,
you should see that option at the end of the property editor for groups or any other elements.
See screenshot below:

Thank you, thatā€™s why I havenā€™t seen that field because I havenā€™t enabled it in Settings. Thank you very much for your help, I understand now and this will come in very handy.

Has anyone found a way to copy a RG and paste it nicely as a table? My tables all end up as a single column.

Had this setup using js first, but this is a great little plugin though!

Where nicely as a table means? As a CSV?
If a particular cell in the RG has multiple elements how would you want it displayed?
You can share you initial js setup and I can take a look to see if I can make it into a plugin for easy usage.

I also didnt have this as part of my initial setup. Was wondering if this would do it out of the box, but it is mosty a formatting issue I think.

When I paste the text from an RG into a text editor or new email in Outlook it pastes all the columns in one column.

So letā€™s say I have a pricing table with 4 columns and 4 rows, the result is 1 column and 8 rows.

However, I have multiple ways of fixing this. Just the copy to clipboard is very resource friendly :slight_smile: (so for me no real need to spend time on a fix tbh)

Hi Sean, thanks so much for the plugin, the copy element works like a charm.

Iā€™m just experiencing a weird bug with the workflow. Though the workflow runs fine (thereā€™s an alert triggered after I push a custom button), it only sometimes copies the text. If I click the button in debug mode running step-by-step, it works every time. If I run it in normal mode, it works sporadically. Iā€™m running the app on the latest version of Chrome on OSX. Any ideas?

Thanks, Richard.

Hmmm, thatā€™s weird.
Please can you try running on a different browser in OSX and also on Chrome on say windows?
That way we will be able to figure out where the source of the issue is coming from.

Thanks

Well that was easy, it works perfectly in Safari! How weird that Chrome would be the problem. Do you have any ideas for an easy fix? I advise my users to use Chrome or Firefox, not Safari (audio / video recorder problems with Safari).

Are you able to find a windows system to test in Chrome on windows. Want to know if its a Chrome issue or Chrome running in OSX.
I havenā€™t had any one report issues with Chrome.

Sorry I donā€™t, itā€™s an Apple household here! Iā€™ll let you know if I run up against any more clues.

A rather big clue here me thinks. In the Chrome console, no errors appear when I click the button with the Air Copy workflow running in ā€˜step by stepā€™ mode, but the following comes up when itā€™s in normal running mode (exactly the same comes up randomly in the live version btw, sometimes works, sometimes doesnā€™t):

Blockquote
Uncaught (in promise) Error: Unable to copy. Perhaps itā€™s not available in your browser?
at triggerCopy (eval at _.create_code (xfalse:96), :102:16)
at triggerCopy (eval at _.create_code (xfalse:96), :99:10)
at eval (eval at _.create_code (xfalse:96), :110:6)
at new Promise ()
at Object.eval [as copy] (eval at _.create_code (xfalse:96), :73:12)
at eval (eval at _.create_code (xfalse:96), :259:12)
at xfalse:97
at T (xfalse:97)
at xfalse:97
at xfalse:99
at Et (xfalse:99)
at evaluate (xfalse:99)
at new e (xfalse:99)
at Object.Ve.Watcher (xfalse:99)
at Object.Ve.run_once (xfalse:99)
at xfalse:97
at Object.Ve.run_without_catching_not_ready (xfalse:99)
at Object.D.i.run (xfalse:97)
at xfalse:93
at xfalse:98
at xfalse:98
at e._attach_success (xfalse:98)
at e.then (xfalse:98)
at e.callback (xfalse:98)
at n.run (xfalse:93)
at xfalse:31
at xfalse:98
at e._attach_success (xfalse:98)
at e.then (xfalse:98)
at t.run_subsequent_actions (xfalse:31)
at xfalse:31
at xfalse:98
at e._attach_success (xfalse:98)
at e.then (xfalse:98)
at t._run_workflow (xfalse:31)
at xfalse:31
at xfalse:98
at e._attach_success (xfalse:98)
at e.then (xfalse:98)
at i (xfalse:31)
at xfalse:31
at xfalse:98
at e._attach_success (xfalse:98)
at e.then (xfalse:98)
at xfalse:31
at xfalse:98
at e._attach_success (xfalse:98)
at e.then (xfalse:98)
at xfalse:31
at xfalse:98
at xfalse:98
at e._attach_success (xfalse:98)
at e.then (xfalse:98)
at e.callback (xfalse:98)
at Object.Ve.run_once (xfalse:99)
at e.freeze_workflows (xfalse:86)
at t.run_workflows (xfalse:31)
at xfalse:36
at xfalse:98
at xfalse:98
at e._attach_success (xfalse:98)
at e.then (xfalse:98)
at e.callback (xfalse:98)
at Object.Ve.run_once (xfalse:99)
at xfalse:36
at xfalse:98
at xfalse:98
at e.resolve (xfalse:98)
at xfalse:99
at t (xfalse:99)
at t (xfalse:99)
at evaluate (xfalse:99)
at Object.run_me (xfalse:99)
at t (xfalse:99)
triggerCopy @ VM15386:102
triggerCopy @ VM15386:99
(anonymous) @ VM15386:110
(anonymous) @ VM15386:73
(anonymous) @ VM15386:259
(anonymous) @ xfalse:97
T @ xfalse:97
(anonymous) @ xfalse:97
(anonymous) @ xfalse:99
Et @ xfalse:99
evaluate @ xfalse:99
e @ xfalse:99
Ve.Watcher @ xfalse:99
Ve.run_once @ xfalse:99
(anonymous) @ xfalse:97
Ve.run_without_catching_not_ready @ xfalse:99
D.i.run @ xfalse:97
(anonymous) @ xfalse:93
(anonymous) @ xfalse:98
(anonymous) @ xfalse:98
e._attach_success @ xfalse:98
e.then @ xfalse:98
e.callback @ xfalse:98
n.run @ xfalse:93
(anonymous) @ xfalse:31
(anonymous) @ xfalse:98
e._attach_success @ xfalse:98
e.then @ xfalse:98
t.run_subsequent_actions @ xfalse:31
(anonymous) @ xfalse:31
(anonymous) @ xfalse:98
e._attach_success @ xfalse:98
e.then @ xfalse:98
t._run_workflow @ xfalse:31
(anonymous) @ xfalse:31
(anonymous) @ xfalse:98
e._attach_success @ xfalse:98
e.then @ xfalse:98
i @ xfalse:31
(anonymous) @ xfalse:31
(anonymous) @ xfalse:98
e._attach_success @ xfalse:98
e.then @ xfalse:98
(anonymous) @ xfalse:31
(anonymous) @ xfalse:98
e._attach_success @ xfalse:98
e.then @ xfalse:98
(anonymous) @ xfalse:31
(anonymous) @ xfalse:98
(anonymous) @ xfalse:98
e._attach_success @ xfalse:98
e.then @ xfalse:98
e.callback @ xfalse:98
Ve.run_once @ xfalse:99
e.freeze_workflows @ xfalse:86
t.run_workflows @ xfalse:31
(anonymous) @ xfalse:36
(anonymous) @ xfalse:98
(anonymous) @ xfalse:98
e._attach_success @ xfalse:98
e.then @ xfalse:98
e.callback @ xfalse:98
Ve.run_once @ xfalse:99
(anonymous) @ xfalse:36
(anonymous) @ xfalse:98
(anonymous) @ xfalse:98
e.resolve @ xfalse:98
(anonymous) @ xfalse:99
t @ xfalse:99
t @ xfalse:99
evaluate @ xfalse:99
run_me @ xfalse:99
t @ xfalse:99
setTimeout (async)
e @ xfalse:99
(anonymous) @ xfalse:99
invalidate @ xfalse:99
e.invalidate @ xfalse:99
e.fire_turned @ xfalse:98
t.turn_on @ xfalse:98
t @ xfalse:99
setTimeout (async)
e @ xfalse:99
(anonymous) @ xfalse:99
e.invalidate @ xfalse:99
e.invalidate @ xfalse:99
e.write_child @ xfalse:53
e.set @ xfalse:53
e.element_clicked @ xfalse:29
(anonymous) @ xfalse:87
dispatch @ xfalse:9
q.handle @ xfalse:9

Great this helps.
I think i have a rough idea what the issue might be.

Are you calling your Copy to clipboard workflow action from a user action, e.g. When a button is clicked?

.

1 Like