Giter Site home page Giter Site logo

tranhl / find-then-jump Goto Github PK

View Code? Open in Web Editor NEW
11.0 11.0 3.0 3.41 MB

Vim Easymotion inspired code navigation.

Home Page: https://marketplace.visualstudio.com/items?itemName=tranhl.find-then-jump

License: MIT License

TypeScript 95.88% JavaScript 4.12%
vscode-extension

find-then-jump's People

Contributors

dependabot[bot] avatar oldstarchy avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

find-then-jump's Issues

Auto focus active group before jumping

Is it possible to always have vscode focusActiveEditorGroup (not sure if thats the right command) before jumping?
My issue is, if I have the terminal focused I can start the find and the active file annotations show up, but the jump does not work/change focus to the file.

I see two ways this could be improved

  1. Dont allow the user to start a find if the editor is not on focus
  2. Always change focus to the file before the jump

Does that makes sense? Im not familiar with writing vscode extensions but I could try to make a PR with the auto focus feature.

Strange behavior in visual mode of vim extension

First of all, The extension is great. I think it's a lightweight version of vim-easymotion

The behavior I expected is that I can select to the text where I jumped. (recorded with vim-easymotion in the vim extension)
expected

But the behavior with this extension is that I just simply jumped without selecting.
now

Is this intended? Maybe a new mode should be added.

Find then jump disappears when autosave is enabled

While editing TypeScript files, I have VSCode set to auto save on focus lost, and apply formatting automatically on save. Pressing the keyboard shortcut that enables Find Then Jump causes the editor to lose focus and to save. This causes Find Then Jump to close automatically right after it opens. When the file is saved before I trigger the keyboard shortcut, the extension works correctly.

Other dialogs such as the file switcher don't seem to disappear automatically when the focus is lost.

To reproduce:

  • Set the Files: Auto Save setting to onFocusChange
  • Enable Editor: Format On Save
  • Enable JavaScript > Format: Enable
  • Create and save an empty JavaScript file
  • Enter a bit of code, then before saving or clicking away from the editor, trigger the extension via a keyboard shortcut

Actual result:
The extensions appears for a split second and then disappears

Expected result:
The extension appears and stays in place

Long startup activation time

The startup time is consistently around 350 - 400ms, which seems to be far too long for what this extension does.

(from Developer: Show running extensions):
image

Is anyone else experiencing this or is it potentially something wrong with my setup?

Most other extensions start up within 50ms

Automatically jump if only one match left.

Thank you for this awesome extension!

Sometimes there's only one match on the entire screen so why not auto jump in those cases? In other words, when there's only one match on the screen (usually hinted as "a"), pressing enter will lead you there.

Keybinding doesn't work with amVim or vscodevim

Hi, amazing extension!

I can't make the keybinding work if amVim or vscodevim are installed.

When I press Ctrl+; I get a notification saying:
Running the contributed command: 'findJump.activate' failed.

The issue only appears if I use it with the keyboard, if I use it from the Command Palette it works as expected.

I disabled Am Vim: Bind Ctrl Commands but the problem persists.

I think the problem is not related with the "Ctrl", because it doesn't work with any shortcut.

Is it supported?

Hello! Thank you for your plugin, it looks awesome, even though a lot of features still are desired.

What is a status of this plugin? Is it still supported? Bug fixes only, or maybe new features are implemented?

I've found several plugins, and of the most interesting is, unfortunately only available for Emacs ;(
https://github.com/abo-abo/avy

Increase number of available matches

As the title says, an option for being able to search just forwards or just backwards, since I know what I'm looking for, why should I also search on both sides? For example, with a remap that would use: s = forward & S = backward.

EDIT: Also a good idea would be to change the matches options, what I mean is that when there't too many matches you start to get MAYUS, and you need to reach shift for that specific word, I would suggest more use of double words matches like fj, sk, ld, etc, in that way you don't loose the flow, or ; that is easier to reach, that can improve more the efficiency

Initiate with current selection

This is a feature suggestion.

Something that I find myself doing is using the initiate command and then searching for a word in the document (usually something already under my cursor) to then get the jump options.

It would be cool if we could maybe add a initiateWithCurrent option that would prefill the text input with the text currently under selection and then let me jump to the matching terms.

I might be able to submit a PR if I find the time. I like the flow of this extension a lot

Miss jump point

Place cursor at N (line 2), then try to jump to the last "Navbar" at the bottom. This is not getting selected as jump point when I type "n", see image.

Sample HTML

<template>
  <Navbar />
</template>

<script lang="ts">
import { defineComponent } from "vue";
import Navbar from "@/components/Navbar.vue"; // @ is an alias to /src

export default defineComponent({
  name: "Home",
  components: {
    Navbar
  }
});
</script>

snap-32

select character before / after the matched one

so I'm trying to select all characters without pressing right after the selection is completed.

  • select after the character when: search direction is down
  • select before the character when: search direction is up

I've tried to fork the project and change some codes. but unfortunately, I'm not good at type script or java script.

Can't show all position of match letters

For example, there are many character 'a' and I want to jump to one of them. But sometime the plugin only show a part of match letters position when I invoke findThenJump.initiate.

The original code overlaps the jump tags

Sometimes my code overlaps the tag letter and it's hard to distinguish them.
This might be caused by the intelisence because this doesn't happen when I disable it.

Is it possible to put the tags in front of everything in the canvas?

I don't know anything about VSCode APIs, but specifying the DecorationOptions parameter of setDecorations API might be the solution.

スクリーンショット 2020-04-20 0 06 48

Known Issues

Incorrect jump-with-selection starting position

When jumping with selection, the resulting selection starts at the cursor's current position. This means that if you have already selected some text, that selection's anchor position is overridden.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.