Code Monkey home page Code Monkey logo

text2book's People

Contributors

thewilley avatar

Stargazers

 avatar  avatar

Watchers

 avatar

Forkers

pargonx

text2book's Issues

Refactor codebase / README

The code is quite hard to follow as it is now. Refactoring it might be a good idea, splitting functions into multiple files, changing variable names, etc.

The same goes for the README file, as it's rather cluttered.

Square brackets don't work with commands

Due to a strange error where I couldn't log in for no apparent reason an admin friend of mine used text2book's commands function to put some books in the game for me.

However they both started and ended up with square brackets and for some reason these square brackets ended up in the title, instead of in the text. It has also eaten a quotation mark.

I am aware this is very much an edge case

For example, this one is supposed to start with a [

image

and end with a "]
image

and the title is not supposed to contain [0]
image

Doesn't seem to always account for line break spacing

Sorry about this but it seems like it doesn't always take into account the space taken up by a line break when splitting books up. In the most recent lore book I made it put in one line's worth more text than actually fit in a page that had a line break in the middle.

Allow users to disable automatic numbering in book title

Presently, a numerical identifier in the form of [n] is appended to the book title during command generation to facilitate differentiation among generated books. Nevertheless, users may desire the option to exclude automatic numbering from their book titles, and this capability should be made available to them.

Allow user to adjust the amount of lines per page

Currently the amount of lines per page is hard-coded to 14, since this is the maximum amount of lines per page. Allowing the user to adjust this value could be useful if they for some reason would not want to use the entire page.

Java Pages Sometimes missing words

The program generates the commands correctly, however, java doesnt display some words at the end of pages sometimes, though the same words that arent showing on java show up on bedrock

also if you check my profile i have forked it for 50 page limit so it works with bedrock (this took me a hour to find the simple line XD)

Add pagination to results

When generating a large amount of text, it can take a while for React to create all textboxes which contains the app results. Pagination would be an easily solution to reduce loading times.

Add support for bedrock

As outlined in #12, the bedrock version of Minecraft only supports 50 pages, while the java version supports 100. A toggle should be added to to switch to either "bedrock mode" or "java mode" in order to support both versions.

website not loading

so i'm trying to go on the text2book website, but my browser (opera gx) keeps giving me errors, saying the website is inaccessible. is there any reason for this ?

Cannot generate text if author and title is not set

If the "Generate Text" option is checked, and the user tries to press "Generate" while no author or title it entered, the app will strait up refuse to generate anything. This is unintentional, as neither an author or title is needed to generate text, but it is required to generate a command.

Fix testing methodology

After further research, it seems like the testing methodology was created in vain, as a small yet important detail was glanced over. The testing document explains that we use the data from a Minecraft world to get the contents of a book within a players inventory. The assumption was that the text displayed in the book GUI would be the same within the .dat file located in the world folder. However, the problem is that the book contents is not truncated within the .dat file, it is done on demand when opening the book GUI. This can even be confirmed when looking at Minecraft's source code:

this.cachedComponents = itextcomponent != null ? GuiUtilRenderComponents.splitText(itextcomponent, 116, this.fontRenderer, true, true) : null;

Essentially the text is split into an array of strings in such a way that they'll fit on a single line on a page. Looking in the .dat file itself we can also confirm that the text is in fact not truncated beforehand, as string which should be way out of page bounds are still stored:

image
Item 6 contains a very long string

image
The book GUI removes the overflowing text

Unless we modify the Minecraft source code, there is basically nothing that can be done about this. The test is essentially useless, as it effectively compares its own output with itself, which always yields a positive test result. I have made some attempts at a solution (including converting the source code to javascript) but to no avail. The testing methodology may have to be changed if a solution cannot be found. I won't put too much time into this if the solution turns out to be more work than worth.

Mark which rows has been copied

When there are a lot of items in the list (see image), you have to constantly find the row you were on last after copying, which is just wasted time. Add a marker (i.e check-mark) which tells the user which one they copied last.

image

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.