Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

iOS 15 Support #1258

Closed
sixiansheng opened this issue Jun 8, 2021 · 52 comments
Closed

iOS 15 Support #1258

sixiansheng opened this issue Jun 8, 2021 · 52 comments

Comments

@sixiansheng
Copy link

这个系统上可以运行扩展,因为他是全平台的,所以有新的开发计划吗?各位小伙伴

@derjanb derjanb changed the title 有猴子是否会在ios 15的系统上有新的发展 iOS 15 Support Jun 10, 2021
@derjanb
Copy link
Member

derjanb commented Jun 10, 2021

I am reviewing this possibility.

However, I am still a little unsure whether there will be any fundamental changes to iOS Safari extensions due to the changes because of Manifest v3 and the newly founded WebExtensions Community Group.

After the deprecation of the legacy Safari Extensions, I already had to completely rewrite the Safari Support (Safari App Extensions), and will now have to do it again for the new Safari Extensions API (#1031).

@derjanb
Copy link
Member

derjanb commented Jul 7, 2021

First investigation showed that no persistent background page can be used at iOS. This means I have to rework Tampermonkey to support this first. This rework is also required for Manifest v3 support.

@btt-t
Copy link

btt-t commented Sep 22, 2021

Just letting you know that extensions are officially available now, meaning if iOS support is ready in the near future, you will be able to release it

@yeniugo
Copy link

yeniugo commented Sep 26, 2021

You can upload to the app store and charge a fee to offset the cost of your account.

@xadamxk
Copy link

xadamxk commented Sep 26, 2021

I already emailed you regarding this topic but I would be more than willing to cover the dev license fee for you @derjanb

@derjanb
Copy link
Member

derjanb commented Sep 26, 2021

I already do have an Apple developer account. Thanks. The problem is that a lot of rework is necessary to support a non-persistent background page. See #1258 (comment)

@rusproject
Copy link

rusproject commented Oct 14, 2021

It would be awesome, any chances that iOS extension will become available this year?

@derjanb derjanb pinned this issue Oct 18, 2021
@ydx1013
Copy link

ydx1013 commented Jan 1, 2022

iOS extension will become available this year?

@derjanb
Copy link
Member

derjanb commented Jan 7, 2022

iOS extension will become available this year?

I tend to say yes. ☺

@ililu2000
Copy link

iOS 上大家可以试试这个App
Maybe you can try this app on iOS Safari
https://apps.apple.com/us/app/userscripts/id1463298887

@newadventure079
Copy link

iOS 上大家可以试试这个App Maybe you can try this app on iOS Safari https://apps.apple.com/us/app/userscripts/id1463298887

This is for MacOS, not iOS.

It's also for iOS. I installed it on my iphone last night

@willl
Copy link

willl commented Jan 17, 2022

iOS 上大家可以试试这个App Maybe you can try this app on iOS Safari https://apps.apple.com/us/app/userscripts/id1463298887

This is for MacOS, not iOS.

The latest version has iOS/iPadOS support, in addition to macOS
See: https://github.com/quoid/userscripts#installation

And screenshot from the app store link
image

@xadamxk
Copy link

xadamxk commented Oct 5, 2022

Have there been any updates regarding iOS? @derjanb
I would love to have Tampermonkey on my mobile - all of these 3rd party alternatives suck.

@derjanb
Copy link
Member

derjanb commented Oct 10, 2022

Kind of. 😇
All preparations for Manifest v3 are going to help to create a real Safari Web Extension that will also run at iOS.

@lhliddal
Copy link

How long do you believe it is until the extension is ready? And will you sell licenses or make it freely available?
Kind regards

@Idanox
Copy link

Idanox commented May 25, 2023

Any news?

@Xaositek
Copy link

Was this ever reconsidered or just allow UserScripts to take over the mobile market?

@derjanb
Copy link
Member

derjanb commented Nov 13, 2023

This is one of my next steps. I needed to convert Tampermonkey to a non-persistent first, which was done for Firefox Android now and I already bought an IPad to be able to develop and test Tampermonkey for iOS.

@Seele0oO
Copy link

Seele0oO commented Dec 1, 2023

Userscript does not seem to provide complete support, and some scripts such as bilibili evo do not run properly.
As reference commit, it does not provide full support.
Thanks again derjanb.

@Gilgamesh-lzq
Copy link

Gilgamesh-lzq commented Dec 1, 2023 via email

@alexchexes
Copy link

Hello, @derjanb! Any news on this?
Checking out this topic for two years and haven't lost hope of seeing a full-featured (or at least half-featured) Tampermonkey for iOS.

Thank you for your work, by the way. I supported you with a small amount recently ;)

@Gilgamesh-lzq
Copy link

Gilgamesh-lzq commented Jul 8, 2024 via email

@derjanb
Copy link
Member

derjanb commented Jul 8, 2024

The new Tampermonkey (web) extension is working fine on macOS. I now have to check iOS...

@alexchexes
Copy link

OH. MY. HOLY. MOLY. GUACAMOLE. GOSH.
I CAN'T BELIEVE IT'S FINALLY HAPPENING. Tampermonkey is coming to iOS, fellas!! Uck yeah!!

@Xaositek
Copy link

Xaositek commented Nov 8, 2024

Well this is an exciting development! TestFlight available yet?

@derjanb derjanb added safari and removed safariapp labels Nov 18, 2024
@derjanb
Copy link
Member

derjanb commented Nov 19, 2024

It's done!

iOS support is there!

The macOS version is still in review, but it should be available soon.

For now Tampermonkey Safari (WebExt version) has these two known issues: #2252 and #2253
Please create a new issue if you find something else.

Free licenses

Again I charge a small fee for this version, because I had to buy Apple hardware to get this done. I hope you understand.
However, for people that

  • donated in the past
  • helped me by posting Github issues and comments
  • develop popular scripts

I'll give a free license.

Just register your email on the Tampermonkey website and follow the steps explained at the email you'll receive.

@zxkmm
Copy link

zxkmm commented Nov 19, 2024

Thanks, just bought it! It's not that cheap in my country based on average purchasing capabilities, but I still bought it to show some supports for nice work.

@icpz
Copy link

icpz commented Nov 19, 2024

Finally! Thanks!

@Xaositek
Copy link

Instant Buy! Thank you so much for doing this @derjanb!

@alexchexes
Copy link

alexchexes commented Nov 19, 2024

Instant buy as well 😂 It's just like my upcoming birthday present lol.
Btw, @derjanb, you could set a price much higher than $2.99 for the launch day — we'd still buy it to support you! ;) Thank you so much for this long-awaited release

@alexchexes
Copy link

And yes, I just tested it — all the essentials work fine: script sync with Google Drive, and scripts that were expected to work on an iPhone are working perfectly. Great job!!!

@ted1030
Copy link

ted1030 commented Nov 19, 2024

Finally! Instant buy!
It’s been such a long time, but I’ve finally seen Tampermonkey on iOS!
I've tested the API GM_setValue, GM_getValue works fine.

But I encountered a problem. if the content of a @resource changes, GM_getResourceText will get the old content.
Manually updating or deleting the resource at the external setting of the userscript is not working, which is the same on Windows Chrome. At this point I can do hard refresh by right click the refresh button, but it is impossible on iOS Safari.
I've found a workaround that visit the resource url directly will force the cache to be updated and GM_getResourceText can get the lastest content.

@derjanb
Copy link
Member

derjanb commented Nov 19, 2024

@ted1030

The "Delete" button only deletes the resource and Tampermonkey relies on browser caching mechanisms to get the resource again.
"Update" should request it in a way that makes the browser not use the cache.

image

@hguandl
Copy link

hguandl commented Nov 20, 2024

Nice work! As a user of Tampermonkey Classic, I wonder whether there is an option to upgrade instead of buying a new App. As far as I know, App Store supports App Bundles. For example, if there is a bundle containing both Tampermonkey and Tampermonkey Classic, classic users would pay price of bundle minus price of Tampermonkey Classic. I would really appreciate it if there would be a little discount for classic users.

@micturkey
Copy link

Nice work! As a user of Tampermonkey Classic, I wonder whether there is an option to upgrade instead of buying a new App. As far as I know, App Store supports App Bundles. For example, if there is a bundle containing both Tampermonkey and Tampermonkey Classic, classic users would pay price of bundle minus price of Tampermonkey Classic. I would really appreciate it if there would be a little discount for classic users.

Agree!
I believe the new app is well worth the price, but it would be even better if there were a discount for existing classic users. Such a gesture would not only show appreciation for loyal users but also encourage more people to make the upgrade.

@ted1030
Copy link

ted1030 commented Nov 20, 2024

The "Delete" button only deletes the resource and Tampermonkey relies on browser caching mechanisms to get the resource again. "Update" should request it in a way that makes the browser not use the cache.

Thanks, I've retried the Update button and it works.

I have another question. Is it possible to add an option to determine whether the enabled state should be overwritten when importing from a backup?
Because some userscripts are targeted at mobile browsers rather than PC browsers.
Or a web extension doesn't have an ios Safari version, so we have to used an alternative userscript.
In these cases I want to sync the script content but exclude the enabled state.

@derjanb
Copy link
Member

derjanb commented Nov 20, 2024

Nice work! As a user of Tampermonkey Classic, I wonder whether there is an option to upgrade instead of buying a new App. As far as I know, App Store supports App Bundles. For example, if there is a bundle containing both Tampermonkey and Tampermonkey Classic, classic users would pay price of bundle minus price of Tampermonkey Classic. I would really appreciate it if there would be a little discount for classic users.

Thanks for the hint.

image

@derjanb
Copy link
Member

derjanb commented Nov 20, 2024

Request for help with the macOS version

I'm not entirely sure if there is one more issue in the macOS version. I got everything working on my end. Especially GM_notification was difficult to get working in iOS, but it's working now.
So I worked on renaming the Safari App based Tampermonkey version to "Tampermonkey Classic", uploaded and published it.
Back at work on the WebExt version, notifications stopped working with

`"UNErrorDomain" error 1, the operation couldn't be completed"

I think this is maybe related to renaming the app, which got the notification permission long time ago, but all tried ways to make macOS forget the extension didn't work.

The macOS version is reviewed and available now. So could someone do me a favor and try the macOS version, and tell me if notifications via GM_notification are working for you?

@alexchexes
Copy link

alexchexes commented Nov 20, 2024

So could someone do me a favor and try the macOS version, and tell me if notifications via GM_notification are working for you?

For me, GM_notification works in both Tampermonkey and Tampermonkey Classic.
I already had Tampermonkey Classic installed back when it was just Tampermonkey. I just installed the new Tampermonkey as well and didn't even turn off "Tampermonkey Classic" during testing. Everything works fine, except that I had to manually enable notifications for Tampermonkey in the settings (there was no automatic prompt for it, although there was for Classic).

Screenshot 2024-11-20 at 12 16 11 Screenshot 2024-11-20 at 12 15 22 Screenshot 2024-11-20 at 12 36 26 Screenshot 2024-11-20 at 12 15 51

Prompt for Classic because I tried GM_notification for the first time:

Screenshot 2024-11-20 at 11 22 40
// ==UserScript==
// @name         Test GM_notification
// @namespace    http://tampermonkey.net/
// @version      2024-07-03
// @description  Test GM_notification
// @author       You
// @match        https://www.tampermonkey.net/*
// @icon         https://www.google.com/s2/favicons?sz=64&domain=tampermonkey.net
// @grant        GM_notification
// ==/UserScript==

(function() {
    'use strict';
    console.log('Tampermonkey NOT classic');

    const test_GM_notification = async () => {
        console.log('test_GM_notification NOT classic');

        GM_notification({
            text: "This is the notification message.",
            title: "Notification Title",
            url: 'https:/example.com/',
            onclick: (event) => {
                // The userscript is still running, so don't open example.com
                event.preventDefault();
                // Display an alert message instead
                alert('I was clicked!')
            }
        });

        const clicked = await GM.notification({ text: "Click me." });
        console.log('clicked', clicked);
    }

    setTimeout(function () {
        test_GM_notification();
    }, 500)
})();

macOS 14.6.1, MBPro M3 Pro.

@derjanb
Copy link
Member

derjanb commented Nov 20, 2024

@alexchexes This looks great. Thank you very much for testing. 😅

@derjanb
Copy link
Member

derjanb commented Nov 23, 2024

Nice work! As a user of Tampermonkey Classic, I wonder whether there is an option to upgrade instead of buying a new App. As far as I know, App Store supports App Bundles. For example, if there is a bundle containing both Tampermonkey and Tampermonkey Classic, classic users would pay price of bundle minus price of Tampermonkey Classic. I would really appreciate it if there would be a little discount for classic users.

The App bundle is available now. Can someone who bought Tampermonkey Classic please check whether the price is the difference between Tampermonkey and Tampermonkey Classic? Thanks

https://apps.apple.com/app-bundle/tampermonkey-bundle/id1780757125

@chensiyue98
Copy link

Nice work! As a user of Tampermonkey Classic, I wonder whether there is an option to upgrade instead of buying a new App. As far as I know, App Store supports App Bundles. For example, if there is a bundle containing both Tampermonkey and Tampermonkey Classic, classic users would pay price of bundle minus price of Tampermonkey Classic. I would really appreciate it if there would be a little discount for classic users.

The App bundle is available now. Can someone who bought Tampermonkey Classic please check whether the price is the difference between Tampermonkey and Tampermonkey Classic? Thanks

https://apps.apple.com/app-bundle/tampermonkey-bundle/id1780757125

It will be 1 euro for the bundle in the Netherlands!
image

@derjanb
Copy link
Member

derjanb commented Nov 23, 2024

Nice work! As a user of Tampermonkey Classic, I wonder whether there is an option to upgrade instead of buying a new App. As far as I know, App Store supports App Bundles. For example, if there is a bundle containing both Tampermonkey and Tampermonkey Classic, classic users would pay price of bundle minus price of Tampermonkey Classic. I would really appreciate it if there would be a little discount for classic users.

The App bundle is available now. Can someone who bought Tampermonkey Classic please check whether the price is the difference between Tampermonkey and Tampermonkey Classic? Thanks
https://apps.apple.com/app-bundle/tampermonkey-bundle/id1780757125

It will be 1 euro for the bundle in the Netherlands! image

Great. So this is the upgrade path for Tampermonkey Classic users.

@derjanb derjanb closed this as completed Nov 25, 2024
@ocd0711
Copy link

ocd0711 commented Nov 26, 2024

Nice work! As a user of Tampermonkey Classic, I wonder whether there is an option to upgrade instead of buying a new App. As far as I know, App Store supports App Bundles. For example, if there is a bundle containing both Tampermonkey and Tampermonkey Classic, classic users would pay price of bundle minus price of Tampermonkey Classic. I would really appreciate it if there would be a little discount for classic users.

The App bundle is available now. Can someone who bought Tampermonkey Classic please check whether the price is the difference between Tampermonkey and Tampermonkey Classic? Thanks
https://apps.apple.com/app-bundle/tampermonkey-bundle/id1780757125

It will be 1 euro for the bundle in the Netherlands! image

Great. So this is the upgrade path for Tampermonkey Classic users.

Does the US not have a bundle? Classic user upgrade or $2.99?
image

@derjanb
Copy link
Member

derjanb commented Nov 26, 2024

The bundle is available in all countries.

image

When creating a bundle one only can add apps, set the price and country availability, add some screenshots and description and that's it.

So please contact Apple support with your Tampermonkey Classic purchase ID and ask them for help.

@xlilu
Copy link

xlilu commented Nov 28, 2024

@derjanb
UI bug in Dark Mode 😂
IMG_0002

@isafe
Copy link

isafe commented Nov 29, 2024

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests