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

UnorderedListIcon not showing #45

Closed
lovenangelo opened this issue May 11, 2024 · 2 comments
Closed

UnorderedListIcon not showing #45

lovenangelo opened this issue May 11, 2024 · 2 comments

Comments

@lovenangelo
Copy link

Screenshot from 2024-05-11 09-53-20

This is all my configuration for the editor but the bullet points icon is not showing

  <EditorProvider>
                    <Editor
                        containerProps={{
                            style: {
                                height: "250px",
                            },
                        }}
                        {...register("description")}
                        defaultValue={watch("description")}
                        value={watch("description")}
                        onChange={(e) => {
                            setDescription(e.target.value);
                            setValue("description", e.target.value);
                        }}
                    >
                        <Toolbar>
                            <BtnBold />
                            <BtnItalic />
                            <BtnUnderline />
                            <BtnBulletList />
                        </Toolbar>
                    </Editor>
                </EditorProvider>

this is the value on user input

"test


  • test
"

@megahertz
Copy link
Owner

@toniswx
Copy link

toniswx commented Jan 28, 2025

If anyone have this problem using react + tailwind,this may serve you:

  • add the styles in some divs
  <div className="rsw-ce h-0 ">
          <ul className="list-disc "></ul>
          <ol className="list-decimal "></ol>
     </div>
  • add absolute to the rsw-ce so it does not show in the screen
  <div className="rsw-ce h-0 absolute">
         <ul className="list-disc "></ul>
         <ol className="list-decimal "></ol>
    </div>
  • place the divs in the editor provider
<EditorProvider>
      <Editor value={value} onChange={onChange}>
        <Toolbar>
          <BtnBold />
          <Separator />

          <BtnItalic />
          <Separator />

          <BtnNumberedList />
          <Separator />
        </Toolbar>
        <div className="rsw-ce h-0 absolute">
          <ul className="list-disc "></ul>
          <ol className="list-decimal "></ol>
         </div>
      </Editor>
    </EditorProvider>

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

No branches or pull requests

3 participants