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

IFrame hinting #2821

Closed
wants to merge 12 commits into from
Closed

IFrame hinting #2821

wants to merge 12 commits into from

Conversation

aartaka
Copy link
Contributor

@aartaka aartaka commented Feb 28, 2023

Description

This is a huge work-in-progress to finally allow iframes in hints. Only the foundations are implemented, like parsing iframes (done before this PR in cf2a7bf and adjacent commits) and allowing nested search for Nyxt DOM nodes.

Fixes #1526.

Discussion

Don't review yet, it's neither complete nor working :D

Checklist:

Everything in this checklist is required for each PR. Please do not approve a PR that does not have all of these items.

  • I have pulled from master before submitting this PR
  • There are no merge conflicts.
  • I've added the new dependencies as:
    • ASDF dependencies,
    • Git submodules,
      cd /path/to/nyxt/checkout
      git submodule add https://gitlab.common-lisp.net/nyxt/py-configparser _build/py-configparser
    • and Guix dependencies.
  • My code follows the style guidelines for Common Lisp code. See:
  • I have performed a self-review of my own code.
  • My code has been reviewed by at least one peer. (The peer review to approve a PR counts. The reviewer must download and test the code.)
  • Documentation:
    • All my code has docstrings and :documentations written in the aforementioned style. (It's OK to skip the docstring for really trivial parts.)
    • I have updated the existing documentation to match my changes.
    • I have commented my code in hard-to-understand areas.
    • I have updated the changelog.lisp with my changes if it's anything user-facing (new features, important bug fix, compatibility breakage).
    • I have added a migration.lisp entry for all compatibility-breaking changes.
    • (If this changes something about the features showcased on Nyxt website) I have these changes described in the new/existing article at Nyxt website or will notify one of maintainters to do so.
  • Compilation and tests:
    • My changes generate no new warnings.
    • I have added tests that prove my fix is effective or that my feature works. (If possible.)
    • New and existing unit tests pass locally with my changes.

@Ambrevar
Copy link
Member

Ambrevar commented Mar 2, 2023

Let me know if you'd like a pre-review.

FIXME: Hint mode and other functionality is not yet iframe-aware, because the
hint creation is not descending into iframes.
Now it should accept JS-side data too.
This commit is questionable, because:
- It makes processing strictly per-element, because our define-parenscript
  functions don't allow any Lisp-side processing (a high time we had
  one). Per-element processing may result in longer drawing and hint processing
  time.
- The whole infrastructure for hints takes documents now, to cope with
  multi-document structure of documents with iframes (where documents beyond the
  default one are iframe-resident ones).
Because all engines forbid it.
@aartaka
Copy link
Contributor Author

aartaka commented May 23, 2023

After some thought and tinkering with this features, I'm sure it needs to be dropped. IFrames are not intended for hinting, because:

  • Some of these are sandboxed.
  • Others are not modifiable/hintable due to being CORS-isolated due to being in a different domain to that of the main frame.
  • And then the only hintable type is iframes for the same domain.

Which means: most IFrames one encounters in the wild are absolutely un-hintable, and those that are hintable make no sense anyway. Closing this as meaningless.

@aadcg
Copy link
Member

aadcg commented Aug 22, 2023

@aartaka ok to delete this branch?

@aartaka
Copy link
Contributor Author

aartaka commented Aug 22, 2023 via email

@aadcg aadcg deleted the iframe-hinting branch August 23, 2023 06:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

Add iframe support for hint-mode
3 participants