Giter Site home page Giter Site logo

Comments (10)

LukasTy avatar LukasTy commented on May 29, 2024

@ImamJanjua is this something that you are looking for? πŸ€”
Consider checking the customization playground for more examples. πŸ˜‰

from mui-x.

ImamJanjua avatar ImamJanjua commented on May 29, 2024

@LukasTy thanks man!

another thing, calendar is not responsive at all and appears to have fixed dimension, does it have something to do with the breakpoints?

Bildschirmaufnahme.2024-05-13.um.10.17.26.mov

from mui-x.

LukasTy avatar LukasTy commented on May 29, 2024

another thing, calendar is not responsive at all and appears to have fixed dimension, does it have something to do with the breakpoints?

Yes, the calendar has a fixed width just as the material design suggests.
Do you have suggestions on how to make it responsive? πŸ€”

from mui-x.

ImamJanjua avatar ImamJanjua commented on May 29, 2024

@LukasTy shouldn't u know that? πŸ˜„

from mui-x.

LukasTy avatar LukasTy commented on May 29, 2024

shouldn't u know that? πŸ˜„

Well, that's basically an answerβ€”we don't know of a good way to make the calendar UX friendly and responsive, that's why it has the same fixed width as the material design suggests.
It's enough to fit in the portrait orientation of all the modern smallest mobile devices, so, it seems to do the trick. πŸ€”

from mui-x.

ImamJanjua avatar ImamJanjua commented on May 29, 2024

@LukasTy does the calendar has breakpoints and can i acess and modify them?

from mui-x.

LukasTy avatar LukasTy commented on May 29, 2024

does the calendar has breakpoints and can i acess and modify them?

No, there are no explicit breakpoints that are used.
If you want to use the theme breakpoints, then access them and override the styles accordingly. πŸ‘

from mui-x.

ImamJanjua avatar ImamJanjua commented on May 29, 2024

@LukasTy thanks!

do u may know how can change the view with custom header?

const DateCalendar: React.FC<DateCalendarProps<Date>> = (props) => {

  const Header = () => {
    return (
      <div className="flex flex-row justify-center gap-8 ">
         {/* on press go to next month*/}
        <button>
          <ChevronLeft size={22} />
        </button>
          
          {/* on press go to today*/}
        <button>today</button>

        {/* on press go to previous month*/}
        <button>
          <ChevronRight size={22} />
        </button>
      </div>
    );
  };

  return (
    <ThemeProvider theme={theme}>
      <Calendar
        slots={{
          calendarHeader: Header,
        }}                   />
   
  );
};

from mui-x.

michelengelen avatar michelengelen commented on May 29, 2024

@LukasTy thanks!

do u may know how can change the view with custom header?

const DateCalendar: React.FC<DateCalendarProps<Date>> = (props) => {

  const Header = () => {
    return (
      <div className="flex flex-row justify-center gap-8 ">
         {/* on press go to next month*/}
        <button>
          <ChevronLeft size={22} />
        </button>
          
          {/* on press go to today*/}
        <button>today</button>

        {/* on press go to previous month*/}
        <button>
          <ChevronRight size={22} />
        </button>
      </div>
    );
  };

  return (
    <ThemeProvider theme={theme}>
      <Calendar
        slots={{
          calendarHeader: Header,
        }}                   />
   
  );
};

see this #13116 ... is this issue resolved and can be closed @ImamJanjua?

from mui-x.

github-actions avatar github-actions commented on May 29, 2024

The issue has been inactive for 7 days and has been automatically closed.

from mui-x.

Related Issues (20)

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.