• Home
  • Categories
  • Recent
  • Popular
  • Top
  • Tags
  • Users
  • Groups
  • Documentation
    • Home
    • Read API
    • Write API
    • Plugin Development
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
v3.5.2 Latest
Buy Hosting

[nodebb-plugin-color] Colors in posts

Scheduled Pinned Locked Moved NodeBB Plugins
25 Posts 14 Posters 11.8k Views
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • toolitoT Offline
    toolitoT Offline
    toolito GNU/Linux
    wrote on last edited by toolito
    #1

    Hi,
    this is my first plugin ๐ŸŽŠ

    This plugin allow users to use colors in their posts.

    Installation

    npm install nodebb-plugin-color

    Usage

    %(color)[Text]

    color represents the css color applied to the text.
    You can use Hex values, rgb, or name of color.

    gitbub repo

    Hope it's useful ๐Ÿ™‚

    F TannerT 2 Replies Last reply
    6
  • F Offline
    F Offline
    finid
    wrote on last edited by
    #2

    @toolito

    Very, very nice. Some people have been requesting this in the composer, so you've made their day. Thank you.

    1 Reply Last reply
    -1
  • psychobunnyP Offline
    psychobunnyP Offline
    psychobunny
    wrote on last edited by
    #3

    Nice! I already have a feature request ๐Ÿ˜› if you start typing %( it pops open a color picker (maybe use the same code for the popup as the @mentions dropdown)

    anyways thanks for this ๐Ÿ™‚

    1 Reply Last reply
    1
  • julianJ Offline
    julianJ Offline
    julian GNU/Linux
    wrote on last edited by
    #4

    Haha wow, nice work @toolito ! Hope you found the plugin writing process easy to grasp ๐Ÿ™‚

    1 Reply Last reply
    -1
  • F Offline
    F Offline
    finid
    replied to toolito on last edited by
    #5

    @toolito

    I've using this on forum.linuxbsdos.com, but it does work when there are more than one usage on the same line.

    1 Reply Last reply
    0
  • julianJ Offline
    julianJ Offline
    julian GNU/Linux
    wrote on last edited by
    #6

    @toolito @planner Just noticed this running on the NFC Ring forum, and yeah, can't put more than one on one line, even with spaces in between

    1 Reply Last reply
    0
  • TannerT Offline
    TannerT Offline
    Tanner Plugin & Theme Dev
    wrote on last edited by
    #7

    @toolito Thanks for this plugin! It's great!

    1 Reply Last reply
    0
  • TannerT Offline
    TannerT Offline
    Tanner Plugin & Theme Dev
    replied to toolito on last edited by
    #8

    @toolito Any way you could integrate this into the composer?

    ? 1 Reply Last reply
    0
  • ? Offline
    ? Offline
    A Former User
    replied to Tanner on last edited by A Former User
    #9

    @Tanner I saw psychobunny give instructions on how to add a composer button. I may give it a go tomorrow.
    For my own reference (on mobile)

    https://github.com/psychobunny/nodebb-plugin-spoilers/blob/master/static/spoilers.js

    I'll also peek around and see if it's possible to have multiple colors on one line. Be advised though, I am extremely new to Node, so no promises.

    1 Reply Last reply
    1
  • ? Offline
    ? Offline
    A Former User
    wrote on last edited by
    #10

    I've hashed out some code snippets I want to test working off of some of the author's code, and some of psychobunny's. If anyone would be willing to team up for some testing on GitHub, it would be awesome. Trying to add in a composer button seems to have broken my test plugin.

    1 Reply Last reply
    1
  • esiaoE Offline
    esiaoE Offline
    esiao
    wrote on last edited by esiao
    #11

    @toolito Hello, I've updated this plugin to include the missing feature :

    • A button in composer

    • the colorpicker to choose a color

    • and the code is parsed

    • Updated regexp for perf and because I didn't update here you can also use multiple colored words in your texts now.

    https://github.com/Toolito/nodebb-plugin-colors/pull/2

    esiaoE 1 Reply Last reply
    0
  • esiaoE Offline
    esiaoE Offline
    esiao
    replied to esiao on last edited by
    #12

    @toolito Plugin updated for NodeBB 0.6.0 compatibilty
    Now the plugin don't parse what's between code blocks.

    Updated for NodeBB 0.6.x compatibilty & removed parsing between code tags by esiao ยท Pull Request #5 ยท Toolito/nodebb-plugin-colors

    I have updated the plugin for NodeBB 0.6.x. Also managed to finally avoid parsing inside code blocks. Could you give me the ownership on npm as I update the plugin regularly and it would avoid to wait for your review when it's just updates to the plugin. I will always create the PRs here but that's more for NodeBB plugin users that can't use it by themselves if it's not updated. https://docs.npmjs.com/cli/owner I'll let you test and accept the PR. Going to notify NodeBB community of the plugin update.

    favicon

    GitHub (github.com)

    1 Reply Last reply
    0
  • S Offline
    S Offline
    Shaun
    wrote on last edited by
    #13

    Seems like there's been no update from this author for almost a year and the plugin doesn't work with 0.6.0. Can we get responsibility for this transferred to @esiao or something?

    PitaJP 1 Reply Last reply
    0
  • PitaJP Offline
    PitaJP Offline
    PitaJ Global Moderator Plugin & Theme Dev
    replied to Shaun on last edited by
    #14

    @Shaun yeah, @esiao can fork this on GitHub and maybe request that he/she be added to the package naintainers on npm

    1 Reply Last reply
    0
  • psychobunnyP Offline
    psychobunnyP Offline
    psychobunny
    wrote on last edited by psychobunny
    #15

    Seems like @toolito is indeed active though, that issue above was merged by him a few days ago

    EDIT: Maybe he just forgot to publish to npm? Might be best to just bug him on his issue tracker

    esiaoE 1 Reply Last reply
    0
  • esiaoE Offline
    esiaoE Offline
    esiao
    replied to psychobunny on last edited by
    #16

    Yes @toolito is active on Github. But update to this one
    https://github.com/Toolito/nodebb-plugin-colors/pull/6

    I've asked for npm ownership but I don't know if he did it or want to do it. And there's no way on npmjs to see if I'm owner.

    1 Reply Last reply
    0
  • JonDoe12J Offline
    JonDoe12J Offline
    JonDoe12
    wrote on last edited by
    #17

    Is this code still compatible with v6.0.1? Because I've been trying to get the plugin to work, to no avail.

    1 Reply Last reply
    0
  • S Offline
    S Offline
    Silvina
    wrote on last edited by
    #18

    Not working for me too.

    1 Reply Last reply
    0
  • MegaM Offline
    MegaM Offline
    Aza Noriega Community Rep
    wrote on last edited by Mega
    #19

    The plugin in npm is outdated.
    So, if you install it via
    $ npm install nodebb-plugin-color
    you get version at 27 July 2014 that doesn't work.

    If you clone the repo

    $ cd /path/to/NodeBB/node_modules
    $ git clone https://github.com/Toolito/nodebb-plugin-colors
    

    the plugin won't work until you rename folder
    from
    nodebb-plugin-colors
    to
    nodebb-plugin-color


    But there is a way!

    $ cd /path/to/NodeBB/node_modules
    $ npm i git+https://github.com/Toolito/nodebb-plugin-colors  
    

    After that the plugin finally works. (p.s. I didn't tested all claimed functionality, I just became convinced that %(red)[Meow] works)

    ping @toolito

    1 Reply Last reply
    0
  • JonDoe12J Offline
    JonDoe12J Offline
    JonDoe12
    wrote on last edited by
    #20

    Hello @Mega . Just curious, why does :

    $ cd /path/to/NodeBB/node_modules
    $ npm i git+https://github.com/Toolito/nodebb-plugin-colors

    Work when nodebb-plugin-colors < with an "s" is at the end? I thought it supposedly worked without the "s"? Not doubting, just curious as to why it works that way for future reference.

    Thank you for your help so far. I'm booting up Nodebb to test it out.

    MegaM 1 Reply Last reply
    0

Copyright ยฉ 2023 NodeBB | Contributors
  • Login

  • Don't have an account? Register

  • Login or register to search.
Powered by NodeBB Contributors
  • First post
    Last post
0
  • Home
  • Categories
  • Recent
  • Popular
  • Top
  • Tags
  • Users
  • Groups
  • Documentation
    • Home
    • Read API
    • Write API
    • Plugin Development