على الرغم من أنّ Modern Web Guidance يهدف إلى توجيه عملية التطوير نحو نهج "صحيح تلقائيًا"، قد تواجه أحيانًا مشاكل في تفعيل الوكيل أو دقة التنفيذ أو اكتشاف الميزات. يقدّم هذا القسم خطوات تشخيصية لمساعدتك في حلّ المشاكل الشائعة، مثل التأكّد من تفعيل مهارة Modern Web بشكل صحيح من خلال طلباتك أو التحقّق من أنّ الرموز الاحتياطية تتوافق مع حالة Baseline المحدّدة لمشروعك. إذا واجهت عقبات فنية مستمرة أو رصدت إرشادات قديمة، ننصحك بالإبلاغ عن المشكلة لمساعدتنا في الحفاظ على دقة هذه المراجع وفعاليتها.
تشخيص عدم استخدام الوكيل لـ "Modern Web Guidance"
عند تثبيت Modern Web Guidance، يتم توجيه الوكلاء لاستخدامه في أي مهام تطوير ويب. ومع ذلك، يتجاهل الوكلاء أحيانًا هذه التعليمات.
يمكنك توجيه الوكيل صراحةً لاستخدام Modern Web Guidance من خلال إلحاق عبارة مثل "استخدام إرشادات الويب الحديث" في نهاية طلبك.
تتيح بعض برامج الوكيل أيضًا استدعاء مهارة معيّنة مباشرةً باستخدام بنية محدّدة، مثل /modern-web-guidance أو $modern-web-guidance، حسب الوكيل.
يُرجى الرجوع إلى مستندات الوكيل أو سؤاله عن كيفية استدعاء مهارة "modern-web-guidance" مباشرةً في حال عدم التأكّد.
تشخيص الرموز البرمجية "المختلَقة" أو عمليات التنفيذ المخمَّنة
هذا أمر شائع حيث يملأ النموذج اللغوي الكبير الفجوات المعرفية بدون تحذير. لمنع الوكيل من اختراع المعلومات، وجدنا أنّ إلحاق التعليمات التالية بطلباتك مفيد جدًا:
Bring up knowledge gaps and don't attempt to guess implementation. List them as open questions.
تشخيص تعذُّر تفعيل إرشادات معيّنة
إذا كنت تستهدف حالة استخدام ميزة معيّنة ولم يكتشفها الوكيل، تأكَّد من أنّ طلباتك تتضمّن كلمات رئيسية محدّدة ومتطلبات ربط لضمان إمكانية اكتشافها بشكل صحيح. يساعد ذلك الوكيل في تحديد مسار الإرشادات ذي الصلة (على سبيل المثال: "انتقالات العرض" و"تحسين LCP").
تتبُّع عملية تفكير الوكيل:
- تحقَّق من الناتج لمعرفة ما إذا تم استدعاء مهارة "
modern-web-guidance". - ابحث عن طلب البحث، على سبيل المثال،
npx -y modern-web-guidance@latest search "carousel scroll snap"، وتأكَّد مما إذا كانت الكلمات الرئيسية والأدلة الناتجة هي التي توقّعتها. - تأكَّد من أنّ طلب الاسترداد قد طلب الدليل المناسب، على سبيل المثال:
npx -y modern-web-guidance@latest retrieve "carousel-snap-highlights,carousel-slide-effects,scroll-snap-state-sync".
Create a new folder and create a carousel web app for me that implements scroll-snap.
...
● Bash(npx -y modern-web-guidance@latest search "carousel scroll snap" --skill-version 2026_05_16-c5e7870)
⎿ [{"id":"carousel-snap-highlights","description":"Visually highlight the currently snapped non-interactive item in scroll-snapping carousels, galleries, or full-page swipe experiences. For example, expanding a card when snapped, or revealing hidden
content.","category":"user-experience","featuresUsed":["Container scroll-state queries"],"tokenCount":1442,"similarity":0.7783},
{"id":"carousel-slide-effects","description":"Create a carousel of slides with images or other visual elements, where each slide animates as they enter/center/exit their scroller. For example, the slides may fade-in/fade-out, rotate, get bigger or smaller,
etc.","category":"user-experience","featuresUsed":["Scroll-driven animations","Scroll snap"],"tokenCount":2105,"similarity":0.6625},
{"id":"scroll-snap-state-sync","description":"Synchronize navigation indicators, linked content panels, and analytics tracking with the actively snapped item in a scrollable container.","category":"user-experience","featuresUsed":["Scroll snap events","Scroll
snap"],"tokenCount":1053,"similarity":0.6166},
{"id":"scroll-snap-realtime-feedback","description":"Provide real-time visual feedback in linked UI elements while a user scrolls through snap-aligned content, before the scroll gesture completes.","category":"user-experience","featuresUsed":["Scroll snap events","Scroll
snap"],"tokenCount":1886,"similarity":0.5664},
{"id":"navigation-drawer","description":"Create a navigation drawer component that, when triggered from a menu button, slides in from the side overlayed on top of existing page content, and slides out when dismissed (by swiping away, tapping outside, or pressing
escape).","category":"user-experience","featuresUsed":["inert","Intersection observer","Popover","Registered custom properties","Scroll-driven animations","scroll-initial-target","Scroll snap"],"tokenCount":4317,"similarity":0.5099}]
● Bash(npx -y modern-web-guidance@latest retrieve "carousel-snap-highlights,carousel-slide-effects,scroll-snap-state-sync")
⎿ <output +158 lines>
}, undefined);
if (topEntry) setSelectedParagraph(topEntry.id);
},
{ root: main, threshold: 0.9 // Adjust based on your use case },
);
// Observe all snap targets (e.g., section headers)
document.querySelectorAll('h2').forEach(header => observer.observe(header));
}
- يمكنك أيضًا تشغيل أوامر البحث بنفسك في الوحدة الطرفية لمعرفة الأدلة التي تطابق طلب البحث.
# Search for relevant guides
npx modern-web-guidance@latest search "carousel scroll snap"
الملاحظات
إذا كانت لديك أي أسئلة أو ملاحظات إضافية حول هذه الميزات الجديدة، يُرجى أولاً الاطّلاع على كيفية المساهمة في Modern Web Guidance قبل الإبلاغ عن مشكلة في مستودع GitHub. أثناء إنشاء المشكلة، قدِّم الطلبات الأولية للوكيل ولقطات الشاشة وسجلّات عملية تفكير الوكيل والتغيير النهائي المقترَح في الرمز البرمجي استنادًا إلى هذا التفكير.