- Create Economist SubmissionTracking package correctly: * mainArticle = full blog post content * coverLetter = 216-word SIR— letter * Links to blog post via blogPostId - Archive 'Letter to The Economist' from blog posts (it's the cover letter) - Fix date display on article cards (use published_at) - Target publication already displaying via blue badge Database changes: - Make blogPostId optional in SubmissionTracking model - Economist package ID: 68fa85ae49d4900e7f2ecd83 - Le Monde package ID: 68fa2abd2e6acd5691932150 Next: Enhanced modal with tabs, validation, export 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
32 lines
1 KiB
Python
32 lines
1 KiB
Python
"""|NumberingPart| and closely related objects."""
|
|
|
|
from ..opc.part import XmlPart
|
|
from ..shared import lazyproperty
|
|
|
|
|
|
class NumberingPart(XmlPart):
|
|
"""Proxy for the numbering.xml part containing numbering definitions for a document
|
|
or glossary."""
|
|
|
|
@classmethod
|
|
def new(cls) -> "NumberingPart":
|
|
"""Newly created numbering part, containing only the root ``<w:numbering>`` element."""
|
|
raise NotImplementedError
|
|
|
|
@lazyproperty
|
|
def numbering_definitions(self):
|
|
"""The |_NumberingDefinitions| instance containing the numbering definitions
|
|
(<w:num> element proxies) for this numbering part."""
|
|
return _NumberingDefinitions(self._element)
|
|
|
|
|
|
class _NumberingDefinitions:
|
|
"""Collection of |_NumberingDefinition| instances corresponding to the ``<w:num>``
|
|
elements in a numbering part."""
|
|
|
|
def __init__(self, numbering_elm):
|
|
super(_NumberingDefinitions, self).__init__()
|
|
self._numbering = numbering_elm
|
|
|
|
def __len__(self):
|
|
return len(self._numbering.num_lst)
|