neorg icon indicating copy to clipboard operation
neorg copied to clipboard

Neorg doesn't hide formating characters, eg: like bold, italic, links, etc...

Open mkblast opened this issue 2 years ago • 13 comments

Prerequisites

  • [X] I am using the latest stable release of Neovim
  • [X] I am using the latest version of the plugin

Neovim Version

V0.9.1

Neorg setup

return {
  "nvim-neorg/neorg",
  build = ":Neorg sync-parsers",
  dependencies = { "nvim-lua/plenary.nvim" },
  config = function()
    require("neorg").setup {
      load = {
        ["core.defaults"] = {}, -- Loads default behaviour
        ["core.concealer"] = {
          config = {
            folds = false,
            icon_preset = "diamond"

          }
        },                  -- Adds pretty icons to your documents
        ["core.dirman"] = { -- Manages Neorg workspaces
          config = {
            workspaces = {
              notes = "~/Documents/notes",
            },
            index = "index.norg",
            default_workspace = "notes",
          },
        },
        ["core.keybinds"] = {
          config = {
            neorg_leader = ",",
          }
        },
        ["core.completion"] = {
          config = {
            engine = "nvim-cmp"
          }
        },
        ["core.presenter"] = {
          config = {
            zen_mode = "zen-mode"
          }
        },
      },
    }
  end,
}

Actual behavior

According to Vhyroo from his youtube videos (I only watched the first 2 vid), Neorg should hide the formatting characters on it's own. In my setup it does not.

2023-06-30T21:34:38,545232048+01:00

Expected behavior

As of the video to hide the characters.

Steps to reproduce

It's the same with the default config. So install Neorg following the github instructions.

Potentially conflicting plugins

No response

Other information

No response

Help

None

Implementation help

No response

mkblast avatar Jun 30 '23 20:06 mkblast

See :h conceallevel and :h concealcursor

This is something that really should be in the readme or conceal wiki.

benlubas avatar Jul 01 '23 16:07 benlubas

Many thanks. I set vim.opt.conceallevel = 3 and it's now hidden if I change the line.

Do I close this issue or keep as a reminder to document it in the future?

mkblast avatar Jul 01 '23 21:07 mkblast

it's already documented here https://github.com/nvim-neorg/neorg/blob/c801ae5165423f4c70841e548208c74da86acf72/doc/neorg.norg#L21

arsmoriendy avatar Jul 12 '23 09:07 arsmoriendy

I know, I'm just voting to make it more visible

benlubas avatar Jul 12 '23 10:07 benlubas

I have exact the same issue: links are working, but not hidden. Bold/italic/striked texts are not rendered, but ticks in tasks and stars in lists rendered correctly. Setting conceallevel doesn't help. I'm using alacritty with tmux and nvim-tree renders at least bold text correctly.

Screenshot_20230712_212904

top4ek avatar Jul 12 '23 18:07 top4ek

I got the same issue as the poster before me, setting the conceallevel does not make bold/italic/striked texts concealed and also the links are working but not concealed.

i-interprete-on-the-fly avatar Jul 17 '23 09:07 i-interprete-on-the-fly

are you sure the conceallevel isn't reset anywhere? does it work if you run the command on the cmdline while in a neorg file? (:set conceallevel=2)

max397574 avatar Jul 17 '23 09:07 max397574

Yep, it's(manual command) first what I tried while trying to figure out what's wrong.

top4ek avatar Jul 17 '23 09:07 top4ek

sorry I'm not rly understanding this this is what you get when you ask two questions at once xD

so does it work if you run the command manually?

max397574 avatar Jul 17 '23 09:07 max397574

For me, setting the conceallevel manually does not work either.

i-interprete-on-the-fly avatar Jul 17 '23 10:07 i-interprete-on-the-fly

Oh, yea, sorry. :) level only is set once in lazy's config right before requiring neorg package. Tried setting it after or removing it at all — doesn't affect any visible things.

Only difference i see: When i set the level at 0 nothing is hidden at all. As I understand, it's ok. When I set the level to 1, 2 and 3 there's only star inside a link changes to its regular ASCII look. And it's switches to it's fancy blue look when current line is a line with that link.

One strange thing I've noticed right now: * List and ** List are rendered as a colored dot despite of level setting.

Here's how I configure neorg

top4ek avatar Jul 17 '23 10:07 top4ek

Do we need to open another issue for this? In addition to the previously mentioned aspects, also the code block functionality does not work for me. Edit: :verbose set conceallevel returns 2 as well

i-interprete-on-the-fly avatar Jul 20 '23 13:07 i-interprete-on-the-fly

Since some time ago, concealer began to work properly except one bug with word warp. Will write about it in common thread.

top4ek avatar Sep 19 '23 14:09 top4ek