Git Product home page Git Product logo

react-gemini-scrollbar's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

react-gemini-scrollbar's Issues

After changing the content's size dynamically, it needs a resize event to adjust the scrollbar

I have a div which I add to its children dynamically and as the result its height changes. Once the content's height is changed, the vertical scrollbar will be able to move too far to the bottom, so much that the bar will be cut off by the frame as if it has gone underneath it. But if I resize the window, the recalculation done makes everything alright again.

Is there some way I can fix this problem from my end?

React Deprecation warnings

I'm getting two react deprecation warning:

React.createClass is deprecated and will be removed in version 16. Use plain JavaScript classes instead. If you're not yet ready to migrate, create-react-class is available on npm as a drop-in replacement

Accessing PropTypes via the main React package is deprecated. Use the prop-types package from npm instead

In the latest version of React these warnings were added can you upgrade to conform to the new standards?

Every rerender component gmini container add 17px

GeminiScrollbar.prototype.update = function update() {
this._viewElement.style.width = ((this.element.offsetWidth + SCROLLBAR_WIDTH).toString() + 'px');
this._viewElement.style.height = ((this.element.offsetHeight + SCROLLBAR_WIDTH).toString() + 'px');

Error this. Add SCROLLBAR_WIDTH 17px every state change

Native scrollbar will show if I zoom out the page

If I zoom the page out (make things smaller) any smaller than 90%, the original native scrollbar will show. I think if you hide them deeper to support the worst case scenario of 67% makes sense:

screenshot from 2016-05-20 11 55 18

Apply to whole page

Hi,

I'm trying to use react-gemini-scrollbar in an isomorphic react app, and I have trouble making it work. How do I apply it to the whole page ?

Thanks !

no css files installed

I did

npm install react-gemini-scrollbar --save

then found no node_modules/react-gemini-scrollbar/node_modules/gemini-scrollbar/gemini-scrollbar.css

In fact, there is no node_modules/react-gemini-scrollbar/node_modules folder and no css files anywhere.

onScroll event

does the scroll bar have an onScroll event or an onScrollToBottom event? if it does what are the values passed?

Update gemini-scrollbar dependency to v1.4

Current version still depends on gemini-scrollbar 1.3.x. I believe there was a pretty key change in 1.4 relating to how resizes are triggered, so it would be good to have this.

gm-scroll-view divs increase their height endlessly when visible.

When using the library and the tab is visible, the height CSS rule increases at about 1000 pixels per second, as long as the page is in view. Switching tabs stops this behavior, and the behavior resumes when switching back. This happens for all instance on the page. I've included a screenshot of two instances updating, and the relevant code attached to the event that's doing it.

image

Update: This appears to be related to using nested MUI grids that each have their own instance of Gemini on them, so this bug may be entirely from this specific use.

Render error

I am getting a issue when trying to use Gemini. It's required and such. Any thoughts?

Here is my render....

render: function() {

    var namePrompt = null;

    if(!this.state.hasName) {
      namePrompt = (
          <div className="board-name-prompt-shadow">
            <div isOpen={true} onRequestClose={this.saveName} className="board-name-prompt" >
              <form onSubmit={this.saveName}>
                <h2>This Board Needs A Name</h2>
                <input ref="name" type="text" placeholder="name me!" />
                <button type="submit">Get Started!</button>
              </form>
            </div>
          </div>  
        );
    }

    var settingsCog = null;
    if(this.state.isSuperadmin) {
      settingsCog = <i onClick={this.toggleSettings} className="fa fa-cog board-settings-cog"></i>;
    }
    return (
      <div>
        <GeminiScrollbar>
          <div ref="moduleContainer" className="react-super-container">
            <div key="title" className="react-title"></div>
            <div key="mentions" className="react-mention-view"></div>
            {this.renderModules()}
            {this.renderNewModule()}
            <div key="spacer" className="spacer">X</div>
          </div>
       </GeminiScrollbar>
        {namePrompt}
        {settingsCog}
        {this.renderSettings()}
      </div>
    );
  }
});

Console error
Uncaught Error: Invariant Violation: GeminiScrollbar.render(): A valid ReactComponent must be returned. You may have returned undefined, an array or some other invalid object.

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.