Eugeny, Another approach that we've talked about in the past around this same problem is that rather than having a specific tab type for housing an XBlock, we'd allow XBlocks to expose a course_view, which the XBlock could use to render any course-level content (perhaps configuration details, perhaps something like the Discussions tab, perhaps other uses). Those tabs could be rendered for any XBlock type that appeared in the course.
Questions I have about your proposed implementation: - what will the XBlock usage_key would be? - where will the XBlock content (scope.content) would be stored in OLX? - How does an XBlock define a view that's specific to the tab? - For instance, I assume that the Discussion block would have a different display in the tab than it would inline. -Cale On Tue, Jun 28, 2016 at 9:41 AM, <eug...@opencraft.com> wrote: > My current understanding is that XBlockTab will just provide a "place" > where you can put any XBlock or component, so that it would be displayed in > tab. > > Theoretically it would mean that any XBlock could be added there, and that > XBlock would work exactly the same in tab or in unit. Practically - I don't > know yet - there might be a need for an XBlock to implement some interface > to be able to work in tab, and in that case only certain XBlocks will be > available for tabs. But I would like to avoid that and have a truly generic > solution. > > In two words: the suggested XBlockTab lives in edx-platform and only > "hosts" XBlocks. > > Regards, > Eugeny > @Opencraft <http://opencraft.com> > > On Tuesday, June 28, 2016 at 4:30:00 PM UTC+3, Cristian Salamea wrote: >> >> >> >> On Tue, Jun 28, 2016 at 8:13 AM, Peter Pinch <pdp...@gmail.com> wrote: >> >>> How would this affect course import and export? >>> >>> I believe unrecognized blocks are ignored on import, but that may be >>> harder to do with tabs, since they are specified in policy.json. >>> >> >> In fact question could be extended to: in future any xblock can add a tab >> ? >> >>> >>> I'd also want to make sure that there is some meaningful logging and >>> error messaging to the user when a course is imported and the proper >>> XBlockTab hasn't been installed. >>> >>> On Jun 28, 2016, at 9:06 AM, eug...@opencraft.com wrote: >>> >>> Hello world! >>> >>> *Background*: OEP is a new (suggested) format for proposing changes to >>> Open edX platform. More details: >>> https://github.com/edx/open-edx-proposals/blob/master/oeps/oep-0001.rst >>> >>> *Idea: *Allow XBlocks to be displayed in a course tab (like Progress, >>> Discussion, etc.) >>> >>> *Motivation: * >>> >>> - In order to completely pull out discussions from edx-platform. >>> discussion XModule is (almost) converted to an XBlock >>> <https://github.com/edx/edx-platform/pull/12582>. The next step >>> would be to replace course discussion tab with discussion XBlock-based >>> solution. >>> - This might be useful for building instructor tools (example of a >>> tool that could benefit from this >>> >>> <https://github.com/open-craft/problem-builder/blob/master/problem_builder/instructor_tool.py>). >>> This is related to other thread on mailing list >>> <https://groups.google.com/forum/#!topic/edx-code/Zd2sKQaMhHI> - >>> kind of alternative implementation. >>> >>> *Tentative implementation details: * >>> >>> *tl;dr*: XBlockTab (working name) will be similar to existing StaticTab >>> (powers "Custom Page" feature) and use nested XBlocks concept to allow >>> using any XBlock (component?) in a Tab. >>> >>> Overall, it would work like that: >>> >>> - "Pages" page in Studio will have "Add XBlock Page" button added; >>> this button will cause XBlockTab to be added to a course >>> - In studio XBlockTab will expose UI for adding XBlocks and (most >>> likely) other components (problems, video, etc.), similar to one found in >>> course Outline editor (Unit page). At a glance it looks like it could be >>> exact same UI, but it is not 100% clear yet. >>> - Components added to an XBlockTab will be persisted to the >>> modulestore using the same mechanism to allow nested XBlocks. >>> - In LMS, XBlockTab will render its children (nested) components >>> sequentially - much like "Unit" (aka vertical module). >>> >>> >>> I'm about writing an OEP this week, so feedback and ideas are very >>> welcome. >>> >>> Regards, >>> Eugeny >>> @Opencraft <http://opencraft.com/> >>> >>> -- >>> You received this message because you are subscribed to the Google >>> Groups "General Open edX discussion" group. >>> To view this discussion on the web visit >>> https://groups.google.com/d/msgid/edx-code/ad852782-b1e2-46ba-85bc-8d93db72048a%40googlegroups.com >>> <https://groups.google.com/d/msgid/edx-code/ad852782-b1e2-46ba-85bc-8d93db72048a%40googlegroups.com?utm_medium=email&utm_source=footer> >>> . >>> >>> >>> -- >>> You received this message because you are subscribed to the Google >>> Groups "General Open edX discussion" group. >>> To view this discussion on the web visit >>> https://groups.google.com/d/msgid/edx-code/CFAAC85C-CE8E-4A56-819C-F1610A0C730A%40gmail.com >>> <https://groups.google.com/d/msgid/edx-code/CFAAC85C-CE8E-4A56-819C-F1610A0C730A%40gmail.com?utm_medium=email&utm_source=footer> >>> . >>> >> >> >> >> -- >> >> >> [image: Cristian Salamea on about.me] >> >> Cristian Salamea >> about.me/ovnicraft >> <http://about.me/ovnicraft> >> > -- > You received this message because you are subscribed to the Google Groups > "General Open edX discussion" group. > To view this discussion on the web visit > https://groups.google.com/d/msgid/edx-code/70e847c6-b42e-470f-8ea2-9ffba6d81e2f%40googlegroups.com > <https://groups.google.com/d/msgid/edx-code/70e847c6-b42e-470f-8ea2-9ffba6d81e2f%40googlegroups.com?utm_medium=email&utm_source=footer> > . > -- You received this message because you are subscribed to the Google Groups "General Open edX discussion" group. To view this discussion on the web visit https://groups.google.com/d/msgid/edx-code/CABSDBxAQNA59MkGQL4%2B%3DuN7Zs8npLheXZ8AXaQ8y-8ckjAT5rg%40mail.gmail.com.