Re: [Django] #12264: calendar.js depends on jsi18n but date widgets using it do not specify as required media

13 views
Skip to first unread message

Django

unread,
May 14, 2011, 1:55:29 PM5/14/11
to django-...@googlegroups.com
#12264: calendar.js depends on jsi18n but date widgets using it do not specify as
required media
----------------------------------------+------------------------
Reporter: tblanchard@… | Owner: nobody
Type: New feature | Status: new
Milestone: | Component: Forms
Version: 1.1 | Severity: Normal
Resolution: | Keywords:
Triage Stage: Accepted | Has patch: 0
Needs documentation: 0 | Needs tests: 0
Patch needs improvement: 0 | Easy pickings: 0
----------------------------------------+------------------------
Changes (by ramiro):

* type: Bug => New feature
* easy: => 0


Comment:

IMHO being able to reuse admin widgets in out own apps isn't parr of the
design objectives of thes widgets. I think being able to achieve that
should be possible but the developer needs to perform all the steps needed
for the integration, just like with any other front end component. I
particularly don't like at all having to devise a way to magically add a
view like the one serving the jsi18n catalog to the URL map of the third
party app.

--
Ticket URL: <http://code.djangoproject.com/ticket/12264#comment:3>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

Django

unread,
Mar 8, 2024, 6:51:46 PM3/8/24
to django-...@googlegroups.com
#12264: calendar.js depends on jsi18n but date widgets using it do not specify as
required media
------------------------------+------------------------------------
Reporter: tblanchard@… | Owner: nobody
Type: New feature | Status: new
Component: Forms | Version: 1.1
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
------------------------------+------------------------------------
Changes (by Adam Zapletal):

* cc: Adam Zapletal (added)

Comment:

It looks like this is still valid. Supporting this idea doesn't seem very
straightforward given the dynamic nature of
`django/views/templates/i18n_catalog.js`. I agree with the comment above
that it's ok if a user wanting to use admin-specific widgets that aren't
designed to be used outside of the admin may have to do a bit of extra
integration work.

If a user wants to use the widgets without internationalization, they
should be able to define simple JavaScript stubs for `gettext`,
`pgettext`, and `get_format` to get things working. If they want to use
internationalization, I feel like having to do the same kind of
integration that the admin does is acceptable.

Considering the above, does this bit of the docs on form media seem
misleading?
https://github.com/django/django/blob/73df8b54a2fab53bec4c7573cda5ad8c869c2fd8/docs/topics/forms/media.txt#L21-L32
--
Ticket URL: <https://code.djangoproject.com/ticket/12264#comment:5>

Django

unread,
Apr 8, 2024, 12:03:30 PM4/8/24
to django-...@googlegroups.com
#12264: calendar.js depends on jsi18n but date widgets using it do not specify as
required media
------------------------------+------------------------------------
Reporter: tblanchard@… | Owner: nobody
Type: New feature | Status: new
Component: Forms | Version: 1.1
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
------------------------------+------------------------------------
Changes (by Natalia Bidart):

* cc: Claude Paroz, Tom Carrick (added)

Comment:

Tom, Claude, would you have further insights for the comment:5 above?
--
Ticket URL: <https://code.djangoproject.com/ticket/12264#comment:6>

Django

unread,
Apr 8, 2024, 12:34:18 PM4/8/24
to django-...@googlegroups.com
#12264: calendar.js depends on jsi18n but date widgets using it do not specify as
required media
------------------------------+------------------------------------
Reporter: tblanchard@… | Owner: nobody
Type: New feature | Status: new
Component: Forms | Version: 1.1
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
------------------------------+------------------------------------
Comment (by Tom Carrick):

I agree completely. In my mind, the admin widgets aren't really that
suitable for use in user code. If people want to use them, fine, but I
think it should be at their own risk and we shouldn't add any extra
maintenance burden in supporting this.

With this piece of documentation, I feel like is suggesting that any
visible change we make to a widget could be backwards incompatible and I
don't think we want that, at least I personally would like the freedom to
change the admin widgets between releases to make improvements without
worrying too much that they might affect someone's site otherwise.

I think we should discourage this by at a minimum removing this paragraph
and closing this ticket.

Just my opinion, anyway :)
--
Ticket URL: <https://code.djangoproject.com/ticket/12264#comment:7>

Django

unread,
Apr 8, 2024, 4:15:55 PM4/8/24
to django-...@googlegroups.com
#12264: calendar.js depends on jsi18n but date widgets using it do not specify as
required media
------------------------------+-----------------------------------------
Reporter: tblanchard@… | Owner: Adam Zapletal
Type: New feature | Status: assigned
Component: Forms | Version: 1.1
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
------------------------------+-----------------------------------------
Changes (by Adam Zapletal):

* owner: nobody => Adam Zapletal
* status: new => assigned

Comment:

Thanks for the activity here! I'm happy to open a pull request when a
consensus is reached.
--
Ticket URL: <https://code.djangoproject.com/ticket/12264#comment:8>

Django

unread,
Oct 4, 2025, 11:20:15 PM (2 days ago) Oct 4
to django-...@googlegroups.com
#12264: calendar.js depends on jsi18n but date widgets using it do not specify as
required media
------------------------------+------------------------------------
Reporter: tblanchard@… | Owner: (none)
Type: New feature | Status: new
Component: Forms | Version: 1.1
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
------------------------------+------------------------------------
Changes (by Adam Zapletal):

* owner: Adam Zapletal => (none)
* status: assigned => new

--
Ticket URL: <https://code.djangoproject.com/ticket/12264#comment:9>
Reply all
Reply to author
Forward
0 new messages